Processing Jupyter Notebooks
Export Code Cells Into *.py
File
- mastersign.datascience.notebook.export_cell_code.export_cell_code(nb_file, py_file=None, tag='production')[source]
Take the source of all code cells, tagged with the given tag, from the given notebook and write them into a Python code file.
- Parameters:
nb_file – A path to a Jupyter Notebook.
py_file – A path to a Python script file as target.
tag – A tag name for the code cell selection. Defaults to
production
.