How to take advantage of GPUs and TPUs for your ML project (Coding TensorFlow)

Поділитися
Вставка
  • Опубліковано 16 січ 2025

КОМЕНТАРІ • 77

  • @bobsalita3417
    @bobsalita3417 5 років тому +6

    Perfectly written, edited and presented script. You're a star.

    • @DeepFrydTurd
      @DeepFrydTurd 10 місяців тому

      thats a virtual robot my guy you been fooled

  • @malharjajoo7393
    @malharjajoo7393 5 років тому +35

    The TPU part of explanation was not clear at all !

  • @yoloswaggins2161
    @yoloswaggins2161 5 років тому +6

    2:50 you're not building a data generator with tf logging, that just produces lines for the log output doesn't come anywhere near your model.

  • @thejesh4514
    @thejesh4514 Рік тому

    3:27 -> 2019: AI can't be the Bard yet, 2023: Introducing Google Bard

  • @luischacon739
    @luischacon739 4 роки тому +4

    Hi! I tried to test the GPU as shown in the video and IT DOESN'T WORK.
    The first error is related to " tf-nightly-gpu-2.0-preview" package which is not found by pip-Colab so there's no TensorFlow instalation. The associated error is the following: ERROR: No matching distribution found for tf-nightly-nightly-gpu-2.0-preview
    To fix the download I checked in TensorFlow documentation ( www.tensorflow.org/install/gpu ) and use their instalation recomendation: " !pip install tf-nightly ". That fix just the download because it still not finding any GPU.
    Anyone know how to completely fix it?

    • @deneb6139
      @deneb6139 4 роки тому

      1. make sure your pip is upgraded to latest version
      2. given this video is an year old now. Follow the instruction here: www.tensorflow.org/install/pip
      3. use release version if you just want to test this code and does not required it in production.
      4. make sure to select GPU in menu Runtime --> Change Runtime Type

    • @Mayur7Garg
      @Mayur7Garg 4 роки тому +2

      Instead of installing " tf-nightly-gpu-2.0-preview", install "tensorflow-gpu" using "!pip install tensorflow-gpu". For the rest of the MNIST code, proceed identically as written in the video.

  • @vratislavruzek2264
    @vratislavruzek2264 4 роки тому +6

    I wonder what would Shakespeare thought about this.

  • @atulgiri8930
    @atulgiri8930 5 років тому +4

    May I know why you used input_dim value as 256 in the Embedding layer?

  • @rekkamkousseila6195
    @rekkamkousseila6195 4 роки тому +1

    Hi, my session is crushing everytime with google colab because the entire ram is used(this is the eroor that i get) so i increased the ram to 25go but still having the same problem so could you please help me i need your help, thank you.

  • @gaous
    @gaous 3 роки тому

    I know its too late but is it still possible to share notebook for the gpu one? I see notebook only for the tpu one.

  • @ayush.pratap.singh.
    @ayush.pratap.singh. 4 роки тому +2

    Can anyone tell me when to use GPU and when to use TPU clearly?

  • @anandnataraj6599
    @anandnataraj6599 5 років тому +1

    The biggest problem is that, if i choose TPU or GPU the ram depletes faster and the system crashes in colab

  • @alejandroholguinmora8781
    @alejandroholguinmora8781 3 роки тому +2

    For a couple of days I been having 12.6 GB RAM available although I have Google Colab Pro+.
    Important to mention that I always run the next lines of code and get the same answer.
    import tensorflow as tf
    tf.test.gpu_device_name()
    /device:GPU:0
    Is there a code that I need to run and be able to get all the RAM that is mention in the Pro+ description?
    Is there a way to know how much RAM have I spent and how much do I have left?
    I´m getting a little bit fustrated that all the process that I run go down all the time

  • @ugaray96
    @ugaray96 5 років тому +9

    What do you need to change to adapt your code for TPU training?

    • @Aoitetsugakusha
      @Aoitetsugakusha 5 років тому

      If your model is built with tensorflow or another framework that supports TPU acceleration, you shouldn't need to change anything. Build your model as usual and the tensorflow backend will handle the optimization. You should add the code block mentioned in this video at the beginning of your code somewhere, though, just to confirm whether or not your notebook or script is properly registering the TPU.

    • @MargaretMaynardReid
      @MargaretMaynardReid 5 років тому +4

      Here is a great blog post 'Keras on TPUs in Colab" - medium.com/tensorflow/tf-keras-on-tpus-on-colab-674367932aa0

  • @charlym1044
    @charlym1044 5 років тому

    So when should one pick one over the other?

  • @shwetaredkar734
    @shwetaredkar734 5 років тому +1

    Even If I set runtime to GPU, it doesn't execute faster. It's way too slow and after some time it crashes. I guess, it waits till the time the GPU is made available to your code. Any solution for it to work faster and utilize the GPU effectively?

  • @TheImpressionable
    @TheImpressionable 5 років тому

    Does you need to be in the States for this to work?

  • @mohithraju8452
    @mohithraju8452 4 роки тому +1

    I have an AMD GPU. Is there a way in which I can use lastest version of tensorflow?

    • @deneb6139
      @deneb6139 4 роки тому

      ever tried plaidml?

    • @krishnar754
      @krishnar754 4 роки тому

      @@deneb6139 even I have the same issue.
      Can u pls elaborate what and how to use that plaidml.. please ..
      I hope you'll reply. Thanks in advance

    • @hmm7458
      @hmm7458 4 роки тому +1

      currently tf is only avail for Nvidia GPU's

    • @Interestingworld4567
      @Interestingworld4567 3 роки тому

      @@hmm7458 Because their GPUs have TPUs.

  • @RichardBaileyrichoncode
    @RichardBaileyrichoncode 4 роки тому +1

    Great video. Thank you.

  • @sepehrnem9773
    @sepehrnem9773 4 роки тому

    Thanks for the video but at the TPU part, "tpu.contrib" has been deprecated

  • @AlanDeRossett
    @AlanDeRossett 5 років тому

    We can use local resources only so testing in cloud is extra work.

  • @peterpirog5004
    @peterpirog5004 5 років тому +1

    Is possible to run TPU calculations without Colab, for example with pyCharm?

    • @supersani21
      @supersani21 2 роки тому

      You'd need probably need to make use of Google Cloud to access the TPU then

  • @sarbajitg
    @sarbajitg 3 роки тому +1

    When to use GPU and when to use TPU?

    • @AlPhA_ATG
      @AlPhA_ATG 4 місяці тому

      You are working on a less complex model use a GPU , if you're working on a Large Complex model like GAN and Transformers use TPU

  • @goodrumour
    @goodrumour 5 років тому +3

    Its giving me error 'SystemError: GPU device not found'
    any help?

    • @hmm7458
      @hmm7458 4 роки тому +1

      it means your system didn't have a GPU

  • @vikassaini1935
    @vikassaini1935 4 роки тому

    so for everyone who is thinking about tpu,,, it is just special chip designed for computing tensors

  • @kloszi
    @kloszi 5 років тому +2

    Plz add link to src

    • @TensorFlow
      @TensorFlow  5 років тому +1

      Here it is! bit.ly/2IEIaSV

    • @brianzhang1993
      @brianzhang1993 5 років тому

      @@TensorFlow How about the other notebook, "Tensorflow with CPU vs. GPU"? There's this notebook but it's not quite the same: colab.research.google.com/notebooks/gpu.ipynb

  • @oliverli9630
    @oliverli9630 5 років тому +1

    How many hours do we have for each account?

  • @Otonium
    @Otonium 5 років тому +1

    Great. Please hurry up and create the migration video.

  • @PWOcarlos
    @PWOcarlos 5 років тому +2

    Its Paige! So cool! I am a fan!

  • @sachinjai1765
    @sachinjai1765 3 роки тому

    Can A TPU generated model file run on GPU

  • @ranasagar699
    @ranasagar699 4 роки тому

    How to create Deep learning model ui without GPU on local machine

  • @maxbranco7321
    @maxbranco7321 5 років тому +2

    So if I'm using the super expensive hardware for free, Google owns my soul or something, right?

    • @keyo3945
      @keyo3945 4 роки тому

      Sir, my concern is not whether Google is on our side; my greatest concern is to be on Google's side, for Google is always right.

  • @DeepFrydTurd
    @DeepFrydTurd 10 місяців тому +1

    IM impressed by the deepfake here . Really astonishing

  • @Ardeact
    @Ardeact 4 роки тому

    i have no idea what's going on but very cool

  • @godbennett
    @godbennett 5 років тому

    Excellent

  • @abhijitkalita6002
    @abhijitkalita6002 3 роки тому

    🔥 🔥

  • @hellowill
    @hellowill 5 років тому +1

    NN is just matrices, no wonder GPU works well

    • @DanOneOne
      @DanOneOne 5 років тому

      I train my models on GpuClub com and don't worry about maintaining these huge machines. No investment is the best investment...

    • @DanOneOne
      @DanOneOne 5 років тому

      check gpuclub com, I train my models there

    • @hellowill
      @hellowill 5 років тому

      @@DanOneOne ????

  • @akillarazarar
    @akillarazarar 3 роки тому

    LEONATO.
    Since thou fallst upon a summon, return 0.

  • @alok7485
    @alok7485 5 років тому

    Please provide me email id for the queries . respected please tell i do not have nvidia graphics card .please tell what i can do to install the Tensorflow library

  • @dharmenrakumar8947
    @dharmenrakumar8947 5 років тому

    i love you ma'am. you way of teaching is really nice. I an also follow to you on Udacity for machine learning

  • @selfawaredevices
    @selfawaredevices 5 років тому

    we need edge tpus 2 years ago. invent time machine then deliver your promise. stop giving us crap on youtube and github.

    • @AlanDeRossett
      @AlanDeRossett 5 років тому

      We also can only use Edge and must compute without Cloud or internet from within closed Fog net ao all IOT is built wrong for us.

  • @pleasuretek
    @pleasuretek 5 років тому +1

    I just want to be able to allocate more than 2GB per tensor (for high resolution image classification, on a pretrained feed-forward network, without having to use 'super-resolution' image slicing) ... and a GPU with 256GB of VRAM...

  • @jackreeceejini2522
    @jackreeceejini2522 5 років тому +1

    DynamicWebPaige

  • @tanbirsohail
    @tanbirsohail 5 років тому +2

    U did not share the notebooks. Also not showing comparison between tpu and gpu. Overall. Not a good video.

    • @linkcell
      @linkcell 5 років тому

      Everyone's like: wtf, I learned absolutely nothing new.

    • @TensorFlow
      @TensorFlow  5 років тому

      Here it is! bit.ly/2IEIaSV

    • @linkcell
      @linkcell 5 років тому

      @@TensorFlow thanks!

    • @erosennin950
      @erosennin950 5 років тому

      doesn't work for me

  • @thejak2517
    @thejak2517 5 років тому +1

    Terrible explanation on TPU and I understand this is just a introductory video but it could have been better if you have zoomed in on the code so that it is viewable.