scipy-2023-image-analysis / tutorial

BSD 3-Clause "New" or "Revised" License
6 stars 8 forks source link

Add required jupytext dependency #1

Closed lagru closed 1 year ago

lagru commented 1 year ago

I am assuming that users are encouraged to run the workshop on their own machine, they will need jupytext as a dependency (unless I am missing something).

lagru commented 1 year ago

Seems like there's also other outdated stuff. E.g. documentation still assumes that jupyter notebook and the ipynb format is used. Should @jni should we update everything in that regard or revert to the previous approach? Or am I completely missing context? :thinking:

jni commented 1 year ago

We should indeed update everything (I think) and maybe we should even do that on the original template repo ๐Ÿ˜‚ but that is less of a priority. Key question is the experience of running this in jupyter notebook and jupyter lab even when jupytext is installed. ie I want to make sure that learners aren't confused because markdown-based notebooks aren't easily "clickable" or something...

jni commented 1 year ago

@kne42 can you add me and Lars and collaborators on this repo? ๐Ÿ™

lagru commented 1 year ago

I am curious if you run into any problems with jupytext and jupyterlab. For me, the jupytext commands don't appear in the command palette (seems fine with jupyter notebooks). That's not a problem for the tutorial per se, but doesn't bode well.

lagru commented 1 year ago

Oh, this occurs when I use the environment.yml and conda-forge. Haven't tested with pip-only.

jni commented 1 year ago

@kne42 i suspect you might be busy with the CZI HQ week and might not see this โ€” if so then we might move to my fork since I am going to spend a lot of time on this this week.

@lagru I think as long as the notebooks (md) run then we are ok... ie what jupytext commands do you need?

I've started to work on the README in my local branch but haven't had a chance to push. Sorry about that, but probably don't worry about the README till then.

We also need updated permissions to turn on gh-pages on this repo...

kne42 commented 1 year ago

hi sorry yes i was busy with travelโ€“ ill give u perms now

im not 100% sure how things are built now but id ideally like everything to be written as myst md -> a gh action converts it to .ipynb -> a gh action also runs all the notebooks to make sure they're working and outputs the executed notebooks as a "solution" somewhere

jni commented 1 year ago

im not 100% sure how things are built now but id ideally like everything to be written as myst md -> a gh action converts it to .ipynb -> a gh action also runs all the notebooks to make sure they're working and outputs the executed notebooks as a "solution" somewhere

Jupytext makes the explicit conversion unnecessary. Notebooks are run directly from the markdown and the markdown files can be opened as notebooks. It's pretty sweet!

kne42 commented 1 year ago

i understand that but im worried it might be confusing to the participants

jni commented 1 year ago

Hmmm. You're not wrong, but I don't want to spend my time building a different solution, especially one that requires a gha to make a commit โ€” I really hate dealing with gha permissions. So imho options are:

Typically we leave exercises open and develop solutions live at the workshop, and then commit that.

kne42 commented 1 year ago

convert to notebooks manually locally and add to commits. But all review happens on markdown.

this seems fine to me, id still like a way to "test" notebooks tho

forget about markdown and just use notebooks

id sooner die

Typically we leave exercises open and develop solutions live at the workshop, and then commit that.

ah interesting, i was thinking of (out of bias due to my short attention span), placing individual solutions as snippets in text files and loading them into the cell via the %load ipython magic