【问题标题】:holoview.extension('bokeh') - cannot import extensionholoview.extension('bokeh') - 无法导入扩展
【发布时间】:2018-01-11 14:28:47
【问题描述】:

我想测试 HoloViews,但遇到了几个错误。 我安装了两次(建议使用不同的设置here)。我使用了!pip install holoviews!pip install 'holoviews[recommended]'

安装时我得到了:

Requirement already satisfied: holoviews in /usr/local/lib/python2.7/dist-packages

Requirement already satisfied: param>=1.3.2 in /usr/local/lib/python2.7/dist-packages (from holoviews)

Requirement already satisfied: numpy>=1.0 in /usr/local/lib/python2.7/dist-packages (from holoviews)

/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
  SNIMissingWarning

/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarningenter

所以,我可以导入 HoloViews(它在已安装的软件包列表中,版本为 1.6.2),但随后 holoviews.extension('bokeh') 不起作用。所以我不能用它。

我正在使用

  • Python 2.7.6
  • Jupyter Notebook 5.1.0
  • 散景 0.12.9
  • Numpy 1.13.1
  • 熊猫 0.20.3

如果我能提供任何关于我做错了什么或我能做些什么来解决这个问题的提示,我将不胜感激。我不太熟悉安装软件包。如果您需要更多信息,请告诉我。我花了几个小时搜索/谷歌搜索没有结果的答案。

非常感谢。

【问题讨论】:

    标签: python python-2.7 jupyter-notebook bokeh holoviews


    【解决方案1】:

    包含pip install bokeh,我发现pip install holoviews[recommended] 在干净的Python 2 环境中可以正常工作。这将安装最新的 HoloViews 版本,即 1.9.2。

    您的系统上似乎安装了较旧的 holoviews,因此我建议您在干净的 Python 2 环境中再次尝试。或者,尝试通过运行 pip install holoviews[recommended]==1.9.2 来固定版本。请注意,您还需要散景版本 0.12.13,因此请务必同时运行 pip install bokeh==0.12.13

    【讨论】:

    • 感谢您的回答。我不得不将库的更新传递给其他员工,因为我显然没有对某些文件夹的写入权限。我明确引用了您提示中的版本。当我知道什么有效时,我会告诉你。再次感谢!
    猜你喜欢
    • 2022-06-18
    • 1970-01-01
    • 2018-07-03
    • 1970-01-01
    • 1970-01-01
    • 2019-07-17
    • 2020-08-10
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多