当前位置:   article > 正文

天池实验室安装库时遇到的问题_the following command must be run outside of the i

the following command must be run outside of the ipython shell:

记录一下使用天池实验室GPU安装库过程中遇到的问题:
首先想使用sklearn:

from sklearn.metrics import f1_score
  • 1

但是提示:‘No module named 'sklearn’
新建cell输入:

pip install sklearn
  • 1

输出报错:

The following command must be run outside of the IPython shell:
 $ pip install sklearn
 The Python package manager (pip) can only be used from outside of IPython.
 Please reissue the `pip` command in a separate terminal or command prompt.
 See the Python documentation for more information on how to install packages:
  https://docs.python.org/3/installing/
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6

也就是说天池GPU用的是IPython shell,不能在cell里安装库,所以新建一个Terminal:

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/黑客灵魂/article/detail/791828
推荐阅读
相关标签
  

闽ICP备14008679号