This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A script that moves files to another directory, and renames any files already | |
# present in the output directory | |
import os | |
import os.path | |
from PIL import Image | |
import shutil | |
import argparse as ap | |
from pathlib import Path |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import torch | |
def f(x): | |
return x**3 + (2 * x) | |
x = torch.tensor(2.).requires_grad_() | |
y = f(x) | |
y.backward() #derivative | |
print(x.grad) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
How to install fastai on AWS? | |
After you launch an AWS Ubuntu instance, do the following: | |
$ git clone https://github.com/fastai/fastai | |
$ wget https://repo.continuum.io/archive/Anaconda3-5.0.0.1-Linux-x86_64.sh | |
$ bash Anaconda3-5.0.0.1-Linux-x86_64.sh | |
$ source .bashrc | |
$ cd fastai | |
$ conda env update |