MobilePose-Pi icon indicating copy to clipboard operation
MobilePose-Pi copied to clipboard

Torchvision install guide might be a bit misleading.

Open Zeit42 opened this issue 5 years ago • 1 comments

After installing PyTorch using your guide, I proceeded to install torchvision. I followed the repo you linked and I used the following commands:

cd ~ mkdir torchvision_install && cd torchvision_install git clone https://github.com/pytorch/vision cd vision

And since you suggested we install from source, I followed the repo's guide and ran:

python setup.py install

The installation stops, because I don't have permissions in a certain folder that the setup.py is trying to write to. This is the log:

The following error occurred while trying to add or remove files in the installation directory:

[Errno 13] Permission denied: '/usr/local/lib/python3.5/dist-packages/test-easy-install-4269.write-test'

The installation directory you specified (via --install-dir, --prefix, or the distutils default setting) was:

/usr/local/lib/python3.5/dist-packages/

Perhaps your account does not have write access to this directory? If the installation directory is a system-owned directory, you may need to sign in as the administrator or "root" account. If you do not have administrative access to this machine, you may wish to choose a different installation directory, preferably one that is listed in your PYTHONPATH environment variable.

So instead of just python setup.py install, I do:

sudo python setup.py install

However, I got this error:

RuntimeError: PyTorch does not currently provide packages for PyPI (see status at https://github.com/pytorch/pytorch/issues/566). Please follow the instructions at http://pytorch.org/ to install with miniconda instead.

I tried

sudo python3 setup.py install

Which would make sense. Torchvision requires PyTorch, and PyTorch was installed in python3, as per your guide.

But it seems that I need to have Pillow installed first.

I'll try to go through installing torchvision using python3.5. But it's a bit worrying because in your requirements, you mentioned that the environment is Python 2.7, but so far, the installations seem to be in Python 3.5. Even the OpenCV Install guide for the Raspberry Pi installs it on Python 3.5.

I'll keep this updated as I work on installing torchvision.

Zeit42 avatar Mar 13 '19 00:03 Zeit42