Skip to content

Update setup instructions #342

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

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions episodes/files/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: dc-image
channels:
- conda-forge
dependencies:
- python>=3.11
- jupyterlab
- numpy
- matplotlib
- scikit-image
- ipympl
- imageio
40 changes: 16 additions & 24 deletions learners/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,39 +7,31 @@ Before joining the workshop or following the lesson, please complete the data an

## Data

The example images used in this lesson are available on [FigShare](https://figshare.com/).
The example images and a description of the Python environment used in this lesson are available on [FigShare](https://figshare.com/).
To download the data, please visit [the dataset page for this workshop][figshare-data]
and click the "Download all" button.
Unzip the downloaded file, and save the contents as a folder called `data` somewhere you will easily find it again,
Unzip the downloaded file, and save the contents as a folder called `data` somewhere you will easily find it again,
e.g. your Desktop or a folder you have created for using in this workshop.
(The name `data` is optional but recommended, as this is the name we will use to refer to the folder throughout the lesson.)

## Software

1. Download and install the latest [Anaconda
distribution](https://www.anaconda.com/download/) for your
operating system. Make sure to choose the Python 3 version (as
opposed to the one with Python 2). If you wish to use an existing
installation, be sure to upgrade your scikit-image to at least 0.19.
You can upgrade to the latest scikit-image using the shell command that follows.
1. Download and install the latest [Miniforge distribution of Python](https://conda-forge.org/download/) for your operating system.
([See more detailed instructions from The Carpentries](https://carpentries.github.io/workshop-template/#python-1).)
If you already have a Python 3 setup that you are happy with, you can continue to use that (we recommend that you make sure your Python version is current).
The next step assumes that `conda` is available to manage your Python environment.
2. Set up an environment to work in during the lesson.
In a terminal (Linux/Mac) or the MiniForge Prompt application (Windows), navigate to the location where you saved the unzipped data for the lesson and run the following command:

::::::::::::::::::::::::::::::::::::::::: callout

## Updating scikit-image in an existing Anaconda distribution

```shell
conda upgrade -y scikit-image
```bash
conda env create -f environment.yml
```

::::::::::::::::::::::::::::::::::::::::::::::::::

2. This lesson uses Matplotlib features to display images, and some
interactive features will be valuable. To enable the interactive
tools in JupyterLab, the `ipympl` package is required. The package
can be installed with the command
If prompted, allow `conda` to install the required libraries.
3. Activate the new environment you just created:

```shell
conda install -c conda-forge ipympl
```bash
conda activate dc-image
```

::::::::::::::::::::::::::::::::::::::::: callout
Expand Down Expand Up @@ -83,9 +75,9 @@ e.g. your Desktop or a folder you have created for using in this workshop.

## Instructions for Windows

Launch the Anaconda Prompt program and type `jupyter lab`.
Launch the Miniforge Prompt program and type `jupyter lab`.
(Running this command on the standard Command Prompt will return an error:
`'conda' is not recognized as an internal or external command, operable program or batch file.`)
`'jupyter' is not recognized as an internal or external command, operable program or batch file.`)


:::::::::::::::::::::::::
Expand Down