[D] What do you think of this workflow?
I described it this Twitter thread: https://twitter.com/colobas_/status/1144395631588306945
Transcribing it here:
#Jupyter & #Python people of Twitter, let me know what you think of this:
- Using Jupytext to have my notebooks in percent format, and still be able to work on them as normal notebooks.
- In the code, I have defined classes and functions I might want to import somewhere else
- I’ll also have stuff you’d have in a normal notebook: experiments, markdown, etc
- At the beginning of the notebook I have the following:
- For every block I want to run in “Jupyter mode”, I precede it with
if ipython is not None:
- Every block that isn’t preceded by that is considered to be in “script/module mode”.
- I can use this to have importable stuff, in the same place I have tests and experiments that explain and test its behaviour
- Bonus: I get to use my favourite IDE to write the bulk of my notebook
Share your thoughts!
EDIT: fixed broken image
submitted by /u/colobas