JuliaPy / JuliaPy/PyCall.jl

Support IPython interactive widgets used in Python code

未关闭
#89 11 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
Julia
星标
1.5k
派生
186
PR 合并指标
30 天内没有已合并 PR

描述

If I load something like vispy or Matplotlib's new nbagg backend, which displays in IPython using IPython's interactive-widget API, it would be good to have it work in Julia as well via PyCall ~~and Interact~~.

What I think this would involve:
- Have a new PyInteract package (that requires PyCall, ~~Interact~~, and IJulia).
- `using PyInteract` would `pyimport("IPython.html.widgets")`, and then monkey-patch it to remap some of the low-level function calls:
- Creating a comm object in Python should instead call the corresponding IJulia/Interact routine
- The `on_msg` callback function of that comm object should call back to IPython to handle the message on the Python side.

I don't know the internals of IPython at all, so some advice from @minrk, @fperez, @ellisonbg, and/or @Carreau would be very helpful:
- What is the minimal set of low-level IPython functions to monkey-patch in order to hook up IPython's widget code to the IJulia plumbing?
- Is monkey-patching the right thing here, or is there some better way to install hooks into IPython to change the widget plumbing?

cc: @shashi, @dcjones

贡献指南

这个仓库没有索引到贡献指南

调研方向

Start by reviewing PyCall, IJulia, Interact, and the IPython.html.widgets API described in the issue. Determine the minimal widget and comm hooks needed, and whether monkey-patching is appropriate. Done means a PyInteract package can make IPython interactive widgets such as vispy or Matplotlib nbagg work through Julia.

由索引模型根据 Issue 内容生成。

评估

技术栈
jupyter, python
领域
tooling
Issue 类型
功能
难度
5/5
预计耗时
一周以上
活跃度
停滞
描述清晰度
需要澄清
新手友好度
20/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。