我在使用外部程序包设置jupyter笔记本环境时遇到困难。
!pip install progress.bar
导致:
Collecting progress.bar
Downloading https://files.pythonhosted.org/packages/b4/fb/d45c6a34e1242f4c7abef5f98aeb29e7096518defcf390bd601b5d3148ff/progress_bar-8.tar.gz
Building wheels for collected packages: progress.bar
Building wheel for progress.bar (setup.py) ... done
Created wheel for progress.bar: filename=progress_bar-8-cp36-none-any.whl size=5587 sha256=46b6c1e0cf1940b29e9e7208d4057a4d65986f9e793cea4b369ea833de896108
Stored in directory: /root/.cache/pip/wheels/04/7e/72/b2261521999fc5bc4ca704b6d84722270d478643c366c6594e
Successfully built progress.bar
Installing collected packages: progress.bar
Successfully installed progress.bar
这是成功的。
但是,如何使用呢?
这3个都不起作用:
bar = Bar() # Bar is not definied
import progress.bar #progress it not definied
bar = progress.bar.Bar() #progress is not definied