Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement ideas: update to best practice for installation inside a notebook & add mybinder option #1

Open
fomightez opened this issue Mar 8, 2024 · 2 comments

Comments

@fomightez
Copy link

I see in your notebooks the use of an exclamation point in conjunction with install commands run inside the notebook. I would suggest no longer doing that.
The magic install commands were added to IPython/Jupyter in 2019 so that for installation commands run inside IPython or a running .ipynb file, the installation occurs in the environment where the backing kernel is based. See here for more about that. See the second paragraph here for more about the possible deficiency of the exclamation point in conjunction with pip install. The magic %pip install even works in JupyterLite and has been adopted by Google Colab finally (I need to find this in the logged changes; I thought I had found it). I see you primarily reference using Google Colab , or at least offer that; however, including current best practices would allow others to use your notebooks conveniently in more places. And since you are putting the out there to help other biologists, the use of the magic versions of the install commands is the practice to encourage.

Optional improvement suggestion:
It would be interesting to see how much of this could be converted over to run in Jupyter sessions offered vial MyBinder.org. (I was successful using a session launched from the 'launch binder' badge here up until 'Plot your entire dataset' in Plot&Stats - BoxPlots.ipynb, after skipping the Google Drive mounting. But I didn't have toy data that seemed to work handy, although I will say I didn't try too hard yet.).
Optionally you could already have the installations needed present, such as you get if you go here or here and click 'launch binder'. By already providing an environment with the installations done, you can encourage those learning to get right into running your code. The Google Graveyard is all too real. I think you could even leave the notebooks 'as-is' so they'd still work in Google Colab, but in MyBinder-served sessions they'd be ready to get beyond the installations faster.

Ver minor:
It's spelled Jupyter

@guijacquemet
Copy link
Contributor

Hi @fomightez ,

Thanks a lot for the great suggestions!
The notebooks are mostly compatible with binder but not completely. The interface is also not very interactive out of the box. I will have to play a little to see how to improve.

Cheers

Guillaume

@fomightez
Copy link
Author

I'd be happy to help.
I'm better versed with Vanilla Jupyter than Google Colab.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants