Jupyter Notebook 中 Python 的 "pip install pgmpy" 语句不起作用

The "pip install pgmpy" statement for Python in Jupyter Notebook does not work

当我尝试使用语句“pip install pgmpy”在 Jupyter notebook 中安装“pgmpy”时,notebook 保持“忙碌”状态,沙漏图标在那里停留了很长时间。每次我尝试安装它时,它至少要加载一两个小时,这对我的 Jupyter 笔记本来说是前所未有的。简单地说,什么都没有发生。语句“!pip install pgmpy”也是如此,带有感叹号 运行 作为 shell 命令。在专注于 pgmpy 之前,我还需要安装什么吗?还需要做什么吗?

如果能在这件事上提供任何帮助,我将不胜感激。提前致谢!

您是否按照 https://pypi.org/project/pgmpy/ 中的建议尝试使用 conda install -c ankurankan pgmpy

另外,我建议 运行 你的代码在 Google collab 中。 !pip install pgmpy 应该在那里工作。