-
Notifications
You must be signed in to change notification settings - Fork 138
Open
Description
Rendering a gif image (in my case an animated gif) does not work.
The ipynb cell has:
display(Image(filename=outpath_gif))
which works in ipynb, but sphinx degrades to a text/plain representation and does not show the gif.
I applied a monkeypatch via conf.py in here:
- Our tutorial notebook saves the rotation GIF to a temp file.
- We add Sphinx conf.py monkeypatches to include image/gif in nbsphinx output selection and rendering.
- We patch nbconvert’s output extraction so image/gif gets written as binary bytes to extracted files.
This works nicely and the animated gif shows in our tutorial:
https://deep-mi.org/WhipperSnapPy/dev/tutorials/whippersnappy_tutorial.html
(last cell)
It would be nice if this can be added to nbsphinx directly to avoid the monkey patch, which is not future proof.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels