-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Trying alternative for BinderHub set up
- Loading branch information
1 parent
9322218
commit c1d420c
Showing
3 changed files
with
75 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: covid19 | ||
channels: | ||
- defaults | ||
dependencies: | ||
- joblib=0.14.1 | ||
- jupyterlab=1.2.6 | ||
- matplotlib=3.1.3 | ||
- notebook=6.0.3 | ||
- numpy=1.18.1 | ||
- pandas=1.0.1 | ||
- pip=20.0.2 | ||
- pytest=5.3.5 | ||
- python=3.8.1 | ||
- scipy=1.4.1 | ||
- seaborn=0.10.0 | ||
- statsmodels=0.11.0 | ||
- pip: | ||
- simpy==3.0.11 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
--- | ||
title: "Day 9" | ||
author: "Amy Heather" | ||
date: "2024-06-11" | ||
categories: [compendium] | ||
--- | ||
|
||
::: {.callout-note} | ||
|
||
Continued working on research compendium. | ||
|
||
::: | ||
|
||
## Work log | ||
|
||
### Research compendium | ||
|
||
Explored options for virtual hosting of materials... | ||
|
||
**Google Colab:** | ||
|
||
* Simply add 'tocolab' within the url so it becomes 'githubtocolab.com/' - e.g. <https://githubtocolab.com/pythonhealthdatascience/stars-reproduce-allen-2020/blob/main/reproduction/reproduction.ipynb>. This has a few issues though... | ||
* Won't have the environment set up, so you'll need to pip install dependencies within this script. | ||
* Can't use local materials (e.g. the local sim package) without uploading those files to Google Drive | ||
* Have to "hack" it to correct version of Python | ||
|
||
``` | ||
!python3 --version | ||
!sudo apt-get install python3.8 | ||
!sudo apt-get update -y | ||
!sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.8 1 | ||
!sudo update-alternatives --config python3 | ||
!python3 --version | ||
``` | ||
|
||
[](https://githubtocolab.com/pythonhealthdatascience/stars-reproduce-allen-2020/blob/main/reproduction/reproduction.ipynb)<nbsp> | ||
|
||
**BinderHub:** | ||
|
||
* Created BinderHub config file to use the GHCR image (`reproduction/binderhub/config.yaml`) | ||
|
||
``` | ||
config: | ||
BinderHub: | ||
use_registry: true | ||
image_prefix: ghcr.io/pythonhealthdatascience/covid19:latest | ||
``` | ||
|
||
* Then set up on <mybinder.org>. This set up but had some issues: | ||
* Takes a long time to set-up. | ||
* Test-run of reproduction.ipynb failed - said there was "no module named 'simpy'". | ||
* Displayed whole repository (rather than just the reproduction folder) - but looks like this is not supported by binder as an option - closest is to modify url so it points to a particular notebook - <https://mybinder.org/v2/gh/pythonhealthdatascience/stars-reproduce-allen-2020/HEAD?labpath=reproduction%2Freproduction.ipynb>. | ||
|
||
[](https://mybinder.org/v2/gh/pythonhealthdatascience/stars-reproduce-allen-2020/HEAD?labpath=reproduction%2Freproduction.ipynb) | ||
|
||
* Tried simplifying this ([as Binder recommends against Docker](https://mybinder.readthedocs.io/en/latest/tutorials/dockerfile.html)), so removed the config file and instead copied the environment file into a .binder folder in the root, as then Binder should ignore configuration files elsewhere... |
This file was deleted.
Oops, something went wrong.