During development python scripts and notebooks in solutions/ are kept in sync using jupytext. You should install the jupytext VSCode extension to maintain both ways synchronization between notebooks and scripts
- Install the
jupytextVSCode extension. - Install pre-commit
uv run pre-commit install
- Modify the python scripts in
solutions/. - To create the notebook from the script you can run:
uv run jupytext solutions/05_image_analysis_with_skimage.py --sync
- Keep it out of git tracking, and let the VSCode extension sync the modification from ipynb to py
Exercises should be marked with the following clause:
# --- Exercise
<code>
# ---Markdown cells are written in the following format:
# %% [markdown]
# <some markdown>
#Code cells as:
# %%Please open a PR for new content, fixes, refactoring etc.