User Tools

Site Tools


tutoriais:conda

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
tutoriais:conda [2024-04-16 18:54] – [Tensorflow] gnanntutoriais:conda [2024-04-16 19:33] (current) – [Torch] gnann
Line 25: Line 25:
 ===== Tensorflow ===== ===== Tensorflow =====
 <code bash> <code bash>
-python=3.9 +DISCLAIMER: versão 2.4 ! 
-conda install tensorflow-gpu numpy=1.23.4+conda install tensorflow-gpu numpy=1.23
 </code> </code>
  
 <code python> <code python>
 import tensorflow as tf import tensorflow as tf
-sys_details = tf.sysconfig.get_build_info() +cuda_version = tf.sysconfig.get_build_info()["cuda_version"
-cuda_version = sys_details["cuda_version"+gpu = tf.test.gpu_device_name()
-gpu = tf.config.list_physical_devices('GPU')+
  
-print("GPU: "+print("GPU: "+gpu)
-print(gpu)+
 print("cuda: "+cuda_version) print("cuda: "+cuda_version)
 </code> </code>
Line 43: Line 41:
 <code bash> <code bash>
 # python do sistema # python do sistema
-conda install pytorch-gpu+conda install pytorch torchvision torchaudio pytorch-cuda=12.1 -c pytorch -c nvidia
 </code> </code>
 +
 +<code python>
 +import torch
 +
 +print("gpu: "+torch.cuda.get_device_name(0))
 +print("cuda: "+torch.version.cuda)
 +</code>
 +
 +https://pytorch.org/get-started/locally/
tutoriais/conda.1713304442.txt.gz · Last modified: 2024-04-16 18:54 by gnann

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki