xavier NX安装torchvision

博客搬移到:https://blog.csdn.net/u013171226/article/details/107680337

上一篇文章里面记录了在xavier NX上安装pytorch,https://www.cnblogs.com/cumtchw/p/13273753.html

然后接下来安装torchvision,下面是英伟达官网上的torchvision的安装方法:https://forums.developer.nvidia.com/t/pytorch-for-jetson-nano-version-1-5-0-now-available/72048

$ sudo apt-get install libjpeg-dev zlib1g-dev
$ git clone --branch <version> https://github.com/pytorch/vision torchvision   # see below for version of torchvision to download
$ cd torchvision
$ sudo python setup.py install
$ cd ../  # attempting to load torchvision from build dir will result in import error
$ pip install 'pillow<7' # always needed for Python 2.7, not needed torchvision v0.5.0+ with Python 3.6

然后下面是torch和torchvision的版本对应关系。

 而我们安装的torch版本是1.6版本,并没有对应的torchvison,于是我直接从github上面下载最新的torchvision,https://github.com/pytorch/vision

然后用下面命令安装

$ cd torchvision
$ sudo python setup.py install
$ cd ../  # attempting to load torchvision from build dir will result in import error

 然后用下面的命令进行测试

python3
import torchvison
torchvision.__version__
posted @ 2020-07-10 14:30  cumtchw  阅读(1981)  评论(0编辑  收藏  举报