How do I embed a local video into Jupyter Notebook that I can then convert to a PDF? - pdf

Have a local video that I'd like to embed into a jupyter notebook and then convert that jupyter notebook into a PDF but am having difficulties. Have tried solutions like this but the video does not display properly in the notebook and the converted pdf just has code.

Related

How to use custom tile server for Keplergl in Jupyter Notebook

I am trying to use a custom tile server other them Mapbox for keplergl in Jupyter Notebook.
I added an exported config file from keplergl but it doesn't work.

Matplotlib interactive mode in Kaggle

Is there any way to run a notebook in interactive mode in Kaggle?
In this notebook, I'm getting errors with the get_window_extent method, and the images don't show correctly.

Launch Dash App from Jupyter Notebook using wget?

What i have done is downloaded a already preset skeleton for my dash app using a !wget function in Jupyter Notebook, I was wondering how could i launch the app?
Is there something similar to this line of code i could use python3 spacex_dash_app.py?
Thank you.
The ! symbol passes your commands to the underlying shell running Jupyter.
Similar to prefixing wget with !, you can run !python3 spacex_dash_app.py, after making sure that spacex_dash_app.py is in the same working directory as your Jupyter notebook.

Plotting Xarray images with Geoviews on a Google Colaboratory Notebook

I'm trying to reproduce the code from this link on Google Colaboratory but my Colab Notebook crashes for reasons I don't understand. Is it possible to get this to work properly?
I can confirm the crash in this notebook.
https://colab.research.google.com/drive/1XwlC2onMlTW0mepTN16Pd1Mj0g_T3dNV
This issue has to do with the fact that Cartopy and Shapely aren't friends...
Shapely is preinstalled in Google Colab, causing a plain install of Cartopy to give problems.
You will have to uninstall Shapely first and reinstall it with no-binary.
Also in order for Geoviews to show plots in Google Colab you will have to call gv.extension('bokeh') in every cell where you want to plot something.
Follow this notebook to see the example code of Geoviews working correctly in Google Colab:
https://colab.research.google.com/drive/1sI51h7l-ySoW2bLrU-K1LMm-TYNVBlif

how to open pdf file in jupyter file browser?

I would like to open a pdf file using the jupyter notebook's file browser. However, when I click, it always opens a new tab and shows a dark screen.
I spent a couple of minutes looking for a workaround for this and found a github issue in the jupyter project where OP discovered that the issue is resolved by installing the PDF viewer plugin to Chrome
I just installed it and I am now seeing PDF's from my notebook in Chrome.
If you want to open a pdf file using the jupyter filebrowser, you need to use Firefox - Google Chrome blocks it.
Alternatively, to open the pdf inside a jupyter notebook cell, you can use IFrame - but again, it doesn't work for Chrome.
from IPython.display import IFrame, display
#filepath = "http://wikipedia.org" # works with websites too!
filepath = "file.pdf"
IFrame(filepath, width=700, height=400)