Last active
August 13, 2018 20:22
-
-
Save yf225/a8088757ce8e09ba3d858fd7f0985d42 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| sudo apt-get update | |
| sudo apt-get install -y --no-install-recommends unzip p7zip-full sox libsox-dev libsox-fmt-all | |
| # pillow >= 4.2 will throw error when trying to write mode RGBA as JPEG, | |
| # this is a workaround to the issue. | |
| conda install -y sphinx pandas pillow=4.1.1 | |
| pip install sphinx-gallery sphinx_rtd_theme tqdm matplotlib ipython | |
| git clone https://github.com/pytorch/vision --quiet | |
| pushd vision | |
| pip install . --no-deps # We don't want it to install the stock PyTorch version from pip | |
| popd | |
| # Download dataset for beginner_source/dcgan_faces_tutorial.py | |
| curl https://s3.amazonaws.com/pytorch-datasets/img_align_celeba.zip --output img_align_celeba.zip | |
| sudo mkdir -p /home/ubuntu/facebook/datasets/celeba | |
| sudo chmod -R 0777 /home/ubuntu/facebook/datasets/celeba | |
| unzip img_align_celeba.zip -d /home/ubuntu/facebook/datasets/celeba > null | |
| # To fix the "_tkinter.TclError: no display name and no $DISPLAY environment variable" error, do the following in the script: | |
| # import matplotlib | |
| # matplotlib.use('Agg') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment