【问题标题】:Tqdm 4.28.1 in Jupyter Notebook "IntProgress not found. Please update jupyter and ipywidgets."Jupyter Notebook 中的 Tqdm 4.28.1“未找到 IntProgress。请更新 jupyter 和 ipywidgets。”
【发布时间】:2019-04-14 08:05:31
【问题描述】:

我试图在我的 Python 代码中使用 tqdm_notebook,但我遇到了这个错误

import tqdm

for i in tqdm.tqdm_notebook(range(2, int(total_number)//20):i

错误:

IntProgress not found. Please update jupyter and ipywidgets.
ImportError: IntProgress not found. Please update jupyter and ipywidgets. See https://ipywidgets.readthedocs.io/en/stable/user_install.html

我正在使用 Python 3.7.1 和 tq​​dm 版本 (4.28.1)

【问题讨论】:

    标签: python jupyter-notebook tqdm


    【解决方案1】:

    这对我有用。

    conda install -c conda-forge ipywidgets
    jupyter nbextension enable --py widgetsnbextension
    

    之后重新启动 jupyter notebook 就可以了。

    原来来自here.的解决方案

    【讨论】:

    • 确保这些安装在笔记本使用的环境中!我正在从基本环境运行 jupyter notebook 并在笔记本中选择不同的 conda 环境。这没有用。
    • 安装它会为我杀死 Jupyter Lab。单元不运行,并且与内核断开连接。
    • 更新:我认为这是当前版本 ipywidgets 7.5.1 的问题。 conda install ipywidgets==7.4.2 已修复。
    • 对我有用,非常感谢
    【解决方案2】:

    对于那些不使用 conda 的人:

    pip3 install ipywidgets --user

    【讨论】:

    • 另外,安装后别忘了重启 Jupyter Notebook 的内核。
    【解决方案3】:

    这对我来说很好用:

    conda install ipywidgets==7.4.2
    

    【讨论】:

    • 或者,pip install ipywidgets==7.4.2
    【解决方案4】:

    啊,我的错!只需要安装包 jupyter 和 ipywidgets!

    【讨论】:

      猜你喜欢
      • 2021-09-01
      • 1970-01-01
      • 2021-02-06
      • 1970-01-01
      • 2017-10-04
      • 2018-05-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多