Skip to content

Instantly share code, notes, and snippets.

@simo23
simo23 / gist:5325f53df8f20723d4d9039c26256655
Last active May 6, 2022 11:37
How to download and setup Pytorch, CUDA 9.0, cuDNN 7.0, Anaconda2 with or without sudo rights
### How to download and setup Pytorch, CUDA 9.0, cuDNN 7.0, Anaconda2 with or without sudo rights
# Tested on Ubuntu 16.04, GPU support, pytorch 0.4.1, cuda 9.0, cuDNN 7.0, Anaconda2 version 5.2.0. If you want other versions small changes must be made.
# Note: you can install everything with or without sudo rights ( if you do not have sudo rights we will install everything locally )
### Download and install CUDA 9.0 Toolkit
# Note: NVIDIA drivers can be also installed during the process (if you have the rights)
# Check that the version of your NVIDIA drivers is compatible with CUDA 9.0. If not you should install the drivers or change CUDA version.
# The default installation path is "/usr/local/cuda". You can install here ONLY if you have the rights to do that, otherwise you must install them somewhere else. You can create a folder where you want and then you MUST say to the installation process the path to the folder you created. Example: I create a folder in ~/nvidia_libraries/cuda-9.0/ so when the proce
@simo23
simo23 / tensorflow_finetune.py
Created September 27, 2017 15:43 — forked from omoindrot/tensorflow_finetune.py
Example TensorFlow script for fine-tuning a VGG model (uses tf.contrib.data)
"""
Example TensorFlow script for finetuning a VGG model on your own data.
Uses tf.contrib.data module which is in release v1.2
Based on PyTorch example from Justin Johnson
(https://gist.github.com/jcjohnson/6e41e8512c17eae5da50aebef3378a4c)
Required packages: tensorflow (v1.2)
Download the weights trained on ImageNet for VGG:
```
wget http://download.tensorflow.org/models/vgg_16_2016_08_28.tar.gz