ipympl when jupyter and ipython kernel are in different conda environment
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 文档
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- jupyter-notebook
- 领域
- documentation, tooling
调研方向
首先查看仓库的 README,以及 issue 中提到的 conda、Jupyter kernel 和 nbextension 文档化命令。明确 ipympl 的哪些部分属于 kernel 环境,哪些部分属于 Jupyter 环境,并记录所需的设置和失败症状。此外,还要评估拆分 conda 软件包是否可行;当独立环境工作流得到清晰说明时,即视为完成。
由索引模型根据 Issue 内容生成。
描述
Hi,
Some context
I typically install the jupter notebook in a conda environment, and create a shortcut on the desktop to launch jupyter-notebook.exe (windows 10 64 bits). Then I create an ipython kernel with all dependencies I want to work with in an other environment, and I register this kernel-in-a-conda-environment with the command
ipython kernel install --user --name NameOfMyNewKernel
I find this workflow relatively clean because I can chose when I want to update either my kernel (bleeding edge or very old depending on this situation) independently from the notebook itself.
The problem
As far as I understand ipympl is really 2 packages.
- One is a python package called
ipymplthat must be installed together with youripythonkernel, because you need to writeimport ipymplin your notebook. - The other one is a javascript package (I supposed it is called also ipympl) that must be installed together with the jupyter notebook application. I don't know if the python package is required or not. You also need to make sure that the javascript package is registered as an extension (
jupyter nbextension enable --py --sys-prefix ipympl) by jupyter.
If this is documented somewhere it is well hidden ;-)
The workaround
I installed 2 times the ipympl package, one in my kernel environment, the other in the jpuyter environment. For the latter case, because the python package is also shipped in the ipympl conda package, matplotlib is installed but I think that is useless. With this, everyting works, I am able to see interactive plots in my notebook.
Before figuring out that I needed to install ipympl in the jupyter environment, I received weird error messages without really explaining what the problem was.
Proposal
- Document the problem. I suppose that this repository README coud explain this, but I suppose it should be also documented somewhere in matplotlib and/or jupyter documentation. I must admit I find the jupyter documentation really hard to navigate though.
- Split ipympl conda package in two: one that contains the python package and the other one containing the javascript package.
Thanks
- 主要语言
- Jupyter Notebook
- 星标
- 1.7k
- 派生
- 234
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
matplotlib/ipympl 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 35/100
matplotlib/ipympl#623 · 1 条评论 ·
-
难度 4/5 3-5 天 新手友好度 35/100
matplotlib/ipympl#622 · 13 条评论 ·
-
难度 4/5 3-5 天 新手友好度 42/100
matplotlib/ipympl#612 ·
-
难度 3/5 1-2 天 新手友好度 45/100
matplotlib/ipympl#611 · 4 条评论 ·
-
难度 4/5 3-5 天 新手友好度 42/100
matplotlib/ipympl#609 · 7 条评论 ·
查看 matplotlib/ipympl 的全部 Issue
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 95/100
Git-it-App/git-it-electron#1047 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
neondatabase/website#5944 ·
-
📕documentation
难度 2/5 1-3 小时 新手友好度 75/100
db-ux-design-system/core-web#8239 ·
-
难度 2/5 1-3 小时 新手友好度 70/100
libsdl-org/sdlwiki#1008 ·
-
难度 2/5 1-3 小时 新手友好度 70/100