导入《动手学深度学习》d2lzh_pytorch库

import sys
print(sys.path)

打印出的结果为

[’/Users/jack/anaconda3/lib/python36.zip’, ‘/Users/jack/anaconda3/lib/python3.6’, ‘/Users/jack/anaconda3/lib/python3.6/lib-dynload’, ‘’, ‘/Users/jack/anaconda3/lib/python3.6/site-packages’, ‘/Users/jack/anaconda3/lib/python3.6/site-packages/aeosa’, ‘/Users/jack/anaconda3/lib/python3.6/site-packages/IPython/extensions’, ‘/Users/jack/.ipython’]

将下载好的d2lzh_pytorch文件夹(链接:https://pan.baidu.com/s/1BzvbR5bLx7DVmFJIdsul8g 密码:bbiv)放到上面路径中任意一个,这里我选的是’/Users/jack/anaconda3/lib/python3.6/site-packages’,之后再import d2lzh_pytorch就可以啦

你可能感兴趣的:(其他)