Issue
I'm trying to convert a Jupyter notebook that is using RISE to visualize the slides as a slideshow in the browser into a PDF file. The PDF file should have all pages in landscape mode and resemble the view in the browser. Of course, animations are not possible, but it should be possible to have fragments
either combined in a single PDF slide or spread across multiple sort of "accumulating" slides (i.e. building upon their forerunner slides) .
I've been trying to create my own Jinja template that generates a LaTeX document utilizing the beamer
document class, with not much success so far.
Do you know if there are any tools or templates or exporters or anything available that can help me with this process? Preferably automatically, like, utilizing nbconvert
?
Solution
Figured it out myself. Take these steps:
- launch
jupyter nbconvert --to slides --post serve the_notebook.ipynb
; the browser will open the node hostedthe_notebook.slides.html
- replace the
#
after thethe_notebook.slides.html
in the browser URL with?print-pdf
so that the url looks most likely likehttp://127.0.0.1:8000/the_notebook.slides.html?print-pdf
- print to PDF file
Answered By - Hendrik Wiese
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.