Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
349df13
replace Anaconda with MiniForge
tobyhodges Apr 1, 2025
55346f2
set up an environment for the workshop
tobyhodges Apr 1, 2025
fb6258b
Apply suggestions from code review
tobyhodges Apr 6, 2025
9ae46f2
Remove mention of Py3 vs Py2
tobyhodges Apr 6, 2025
89f5b47
Apply fixes from review
tobyhodges May 7, 2025
9c8345e
Link to central Python install instructions
tobyhodges May 7, 2025
c3355b7
[actions] update sandpaper workflow to version 0.16.12
zkamvar May 13, 2025
228bc8c
Merge pull request #343 from datacarpentry/update/workflows
marcodallavecchia May 13, 2025
7597b4b
Merge pull request #342 from datacarpentry/update-python-setup
tobyhodges May 19, 2025
7e87d73
update maintainers in readme
K-Meech Jun 2, 2025
3982f8c
Merge pull request #344 from datacarpentry/km/update-maintainers
uschille Jun 2, 2025
979c654
add style guidelines to contributing guide
K-Meech Jun 10, 2025
624a104
link to contributing file from readme
K-Meech Jun 10, 2025
6272d04
small fixes to formatting
K-Meech Jun 10, 2025
9293c50
minor changes based on reviews
K-Meech Jun 15, 2025
72bbd95
Merge pull request #345 from datacarpentry/km/contributing-guide
uschille Jun 20, 2025
b3f574e
added further reading section and populated it with initial content
Aug 22, 2025
945efaf
added reference to further reading page at end of capstone challenge …
Aug 25, 2025
6d8aec8
rephrased where to go next section at the end of challenge page
Aug 25, 2025
d43cf5c
updated resources to remove old ones and added a few more recent usef…
Dec 5, 2025
780bd07
fixed quotes and added EPFL resource list
Dec 9, 2025
8fc15b3
dark mode images for episodes 1 and 2
Dec 9, 2025
9a96004
dark mode images episode 3
Dec 9, 2025
67b8fa0
dark mode images episode 4
Dec 9, 2025
55a727e
dark mode image episode 5
Dec 9, 2025
df99ba2
dark mode images episode 6
Dec 9, 2025
1c0cc0f
kept automatic dark mode image for SVG vector image since it doesn't …
Dec 9, 2025
e4dbfda
dark mode images episode 7
Dec 9, 2025
6225e24
reverted histogram images as one of them is without background. Keepi…
Dec 9, 2025
813f2a0
dark mode images episode 8. Added full white background for shapes-01…
Dec 9, 2025
ee58215
dark mode images episode 9
Dec 9, 2025
fc06ed2
dark mode images extra episode edge detection
Dec 9, 2025
5a584c8
[actions] update sandpaper workflow to version 0.18.4
zkamvar Jan 27, 2026
c04bff5
Merge pull request #353 from datacarpentry/update/workflows
uschille Jan 27, 2026
fff6d1c
[actions] update workbench docker version to v0.2.4 (#354)
carpentries-bot Jan 27, 2026
9e443b2
Update sandpaper-version.txt
uschille Jan 27, 2026
1773a12
Merge pull request #355 from datacarpentry/uschille-patch-1
uschille Jan 27, 2026
ced5e7c
[actions] update sandpaper workflow to version 0.18.4
uschille Jan 27, 2026
955b441
Merge pull request #356 from datacarpentry/update/workflows
uschille Jan 27, 2026
b5f761c
[actions] update sandpaper workflow to version 0.18.5
zkamvar Feb 3, 2026
27a02b6
Merge pull request #357 from datacarpentry/update/workflows
K-Meech Feb 3, 2026
17e9308
added contributing guidelines for new images and dark mode
Feb 9, 2026
c875bd1
moved all dark images to from data to fig folder, to leave the data d…
Feb 9, 2026
d006c09
Added and reordered items in further-reading.md
uschille Feb 28, 2026
7b3be7e
Change title of reference.md to Glossary to make 'More'-menu clearer
uschille Feb 28, 2026
82ddb66
Custom order of entries on 'More'-menu
uschille Feb 28, 2026
b7d1991
[actions] update sandpaper workflow to version 1.0.0
zkamvar Mar 3, 2026
5b19786
Merge pull request #359 from datacarpentry/update/workflows
uschille Mar 5, 2026
a952902
Merge pull request #350 from marcodallavecchia/dark-mode-images
K-Meech Mar 20, 2026
82c4c84
removed Studies on application of image processing in various fields …
Mar 23, 2026
751fdea
Merge pull request #348 from marcodallavecchia/add_further_reading_se…
marcodallavecchia Mar 23, 2026
21314ae
chair images are only used in the data but not in the fig directory
Mar 23, 2026
4f18430
colonies01.png not used, just the jpg version is used
Mar 23, 2026
1cffe91
updated root mass values based on fresh new environment
Mar 23, 2026
b958160
added callout block to highlight the importance of reproducible envir…
Mar 23, 2026
f7bd410
updated current repository status with all latest improvements on the…
Mar 24, 2026
5a50ce3
Merge pull request #361 from marcodallavecchia/remove-unused-images
K-Meech Mar 24, 2026
df33620
fix all broken links due to restructuring of episodes structure
Mar 24, 2026
2e23efb
Removed unused images from original datacarpentry/image-processing repo
Mar 24, 2026
ad79637
more updated values after re-running with fresh updated environment
Mar 24, 2026
4da0c08
Merge pull request #362 from marcodallavecchia/root-mass-reproducibility
marcodallavecchia Mar 25, 2026
600086d
pulled latest updated values from fresh environment installation
Mar 25, 2026
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
93 changes: 91 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ your change proposal as promptly as we can, and help you become a member of our
community. Everyone involved in [The Carpentries][cp-site] agrees to abide by
our [code of conduct](CODE_OF_CONDUCT.md).

### Who Should Contribute?

Contributions to this lesson are welcome from anyone with an interest in the project.

### How to Contribute

The easiest way to get started is to file an issue to tell us about a spelling
Expand Down Expand Up @@ -43,7 +47,7 @@ documentation][template-doc].
to [The Workbench documentation][template-doc].


### What to Contribute
### What to Contribute (General)

There are many ways to contribute, from writing new exercises and improving
existing ones to updating or filling in the documentation and submitting [bug
Expand All @@ -58,7 +62,66 @@ are particularly valuable**: it's easy for people who have been using these
lessons for a while to forget how impenetrable some of this material can be, so
fresh eyes are always welcome.

### What *Not* to Contribute
### What to Contribute (This Lesson)

Any contributions are welcome, particularly ideas for how the existing content could be
improved or updated, and/or errors that need to be corrected. Comments on existing issues
and reviews of pull requests are similarly welcome.

If you plan to submit a pull request, please open an issue
(or comment on an existing thread) first to ensure that effort is not duplicated
or spent making a change that will not be accepted by the Maintainers.

#### Content / style guidelines

- If you add an image / figure that was generated from Python code, please include this
code in your PR under `episodes/fig/source`.

- If you add a new image or figure, verify that it displays correctly in the lesson’s dark mode. A color-inversion filter is applied [by Varnish to all images by default in dark mode](https://github.com/carpentries/varnish/issues/181), which may cause some images to appear incorrectly or become unreadable. If your image is affected, include an additional version of the same image with a `-dark` suffix in its filename.

- Use the terms in the table below, when referring to Python libraries within the lesson.
The table gives two terms for each library: `Term for descriptive text` which should be
used when discussing the library in plain English / full sentences and `Term for code`
which should be used when referring to code (and within code).

| Python library | Term for descriptive text | Term for code |
| :------------- | :------------- | :------------- |
| [scikit-image](https://scikit-image.org/) | scikit-image | `skimage` |
| [NumPy](https://numpy.org/) | NumPy | `numpy` |
| [Matplotlib](https://matplotlib.org/) | Matplotlib | `matplotlib` |
| [imageio](https://imageio.readthedocs.io/en/stable/index.html) | imageio | `imageio` |


- When importing scikit-image use:
```python
import skimage as ski
```
Therefore, to access specific functions, you need to use their submodule name. For example:

```python
import skimage as ski

rr, cc = ski.draw.rectangle(start=(357, 44), end=(740, 720))
```

- For reading and writing images, use the [imageio](https://imageio.readthedocs.io/en/stable/index.html)
library and avoid use of `skimage.io`. For example:
```python
import imageio.v3 as iio

chair = iio.imread(uri="data/chair.jpg") # read an image
iio.imwrite(uri="data/chair.tif", image=chair) # write an image
```

- Comments providing an overall description of a code snippet should use triple quotes `"""`, e.g.,
```python
"""Python script to load a colour image in grayscale"""

chair = iio.imread(uri="data/chair.jpg")
gray_chair = ski.color.rgb2gray(chair)
```

### What *Not* to Contribute (General)

Our lessons already contain more material than we can cover in a typical
workshop, so we are usually *not* looking for more concepts or tools to add to
Expand All @@ -72,6 +135,23 @@ platform. Our workshops typically contain a mixture of Windows, macOS, and
Linux users; in order to be usable, our lessons must run equally well on all
three.

### What *Not* to Contribute (This Lesson)

Although most contributions will be welcome at this stage of the curriculum's development,
the time available to deliver the content in a training event is strictly limited
and needs to be accounted for when considering the addition of any new content.
If you want to suggest the addition of new content, especially whole new sections or episodes,
please open an issue to discuss this with the Maintainers first and provide the following
information alongside a summary of the content to be added:

1. A suggested location for the new content.
2. An estimate of how much time you estimate the new content would require in training
(teaching + exercises).
3. The [learning objective(s)][cldt-lo] of this new content.
4. (optional, but strongly preferred)
A suggestion of which of the currently-used learning objectives could be
removed from the curriculum to make space for the new content.

### Using GitHub

If you choose to contribute via GitHub, you may want to look at [How to
Expand All @@ -92,6 +172,14 @@ Each lesson has a team of maintainers who review issues and pull requests or
encourage others to do so. The maintainers are community volunteers, and have
final say over what gets merged into the lesson.

#### Merging Policy

Pull requests made to the default branch of this repository
(from which the lesson site is built)
can only be merged after at least one approving review from a Maintainer.
Any Maintainer can merge a pull request that has received at least one approval,
but they may prefer to wait for further input from others before merging.

### Other Resources

The Carpentries is a global organisation with volunteers and learners all over
Expand All @@ -102,6 +190,7 @@ media, slack, newsletters, and email lists. You can also [reach us by
email][contact].

[repo]: https://github.com/datacarpentry/image-processing
[cldt-lo]: https://carpentries.github.io/lesson-development-training/05-objectives.html#learning-objectives
[contact]: mailto:team@carpentries.org
[cp-site]: https://carpentries.org/
[dc-issues]: https://github.com/issues?q=user%3Adatacarpentry
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ The original ideas and discussions in our first in-person workshop has been arch

Make a suggestion or correct an error by [raising an Issue](https://github.com/carpentries-incubator/bioimage-analysis-python/issues).

Please see the [CONTRIBUTING.md file](CONTRIBUTING.md) for contributing guidelines and details on how to get involved with
this project. Some specific guidelines for content / style are provided in the
['What to Contribute (This Lesson)' section](CONTRIBUTING.md#what-to-contribute-this-lesson).

## Code of Conduct

All participants should agree to abide by the [The Carpentries Code of Conduct](https://carpentrieshandbook.readthedocs.io/en/latest/topic_folders/policies/code-of-conduct.html).
Expand Down
7 changes: 6 additions & 1 deletion config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,12 @@ episodes:
- 10-challenges.md

# Information for Learners
learners:
learners:
- prereqs.md
- discuss.md
- reference.md
- further-reading.md
- edge-detection.md

# Information for Instructors
instructors:
Expand Down
2 changes: 1 addition & 1 deletion episodes/01-introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ As we move through this workshop,
we will learn image analysis methods useful for many different scientific problems.
These will be linked together
and applied to a real problem in the final end-of-workshop
[capstone challenge](09-challenges.md).
[capstone challenge](10-challenges.md).

Let's get started,
by learning some basics about how images are represented and stored digitally.
Expand Down
8 changes: 4 additions & 4 deletions episodes/03-reading-images.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,14 +240,14 @@ Suppose we are interested in this maize root cluster image.
We want to be able to focus our program's attention on the roots themselves,
while ignoring the black background.

![](data/maize-root-cluster.jpg){alt='Root cluster image'}
![](fig/maize-root-cluster.jpg){alt='Root cluster image'}

Since the image is stored as an array of numbers,
we can simply look through the array for pixel colour values that are
less than some threshold value.
This process is called *thresholding*,
and we will see more powerful methods to perform the thresholding task in
[the *Thresholding* episode](07-thresholding.md).
[the *Thresholding* episode](06-processing-segmentation.md).
Here, though, we will look at a simple and elegant NumPy method for thresholding.
Let us develop a program that keeps only the pixel colour values in an image
that have value greater than or equal to 128.
Expand Down Expand Up @@ -379,7 +379,7 @@ the low intensity pixels while changing the high intensity ones.

The file `data/sudoku.png` is an RGB image of a sudoku puzzle:

![](data/sudoku.png){alt='Su-Do-Ku puzzle'}
![](fig/sudoku.png){alt='Su-Do-Ku puzzle'}

Your task is to load the image in grayscale format and turn all of
the bright pixels in the image to a
Expand Down Expand Up @@ -465,7 +465,7 @@ Consider this image of a whiteboard, and suppose that we want to create a
sub-image with just the portion that says "odd + even = odd," along with the
red box that is drawn around the words.

![](data/board.jpg){alt='Whiteboard image'}
![](fig/board.jpg){alt='Whiteboard image'}

Using `matplotlib.pyplot.imshow`
we can determine the coordinates of the corners of the area we wish to extract
Expand Down
4 changes: 2 additions & 2 deletions episodes/04-drawing.md
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ Copy that image to your computer, write some code to make a mask,
and apply it to select the part of the image containing your object.
For example, here is an image of a remote control:

![](data/remote-control.jpg){alt='Remote control image'}
![](fig/remote-control.jpg){alt='Remote control image'}

And, here is the end result of a program masking out everything but the remote:

Expand Down Expand Up @@ -446,7 +446,7 @@ fig, ax = plt.subplots()
ax.imshow(wellplate)
```

![](data/wellplate-01.jpg){alt='96-well plate'}
![](fig/wellplate-01.jpg){alt='96-well plate'}

Suppose that we are interested in the colours of the solutions in each of the wells.
We *do not* care about the colour of the rest of the image,
Expand Down
2 changes: 1 addition & 1 deletion episodes/05-creating-histograms.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ and histograms are also quite handy as a preparatory step before performing
We will start with grayscale images,
and then move on to colour images.
We will use this image of a plant seedling as an example:
![](data/plant-seedling.jpg){alt='Plant seedling'}
![](fig/plant-seedling.jpg){alt='Plant seedling'}

Here we load the image in grayscale instead of full colour, and display it:

Expand Down
18 changes: 9 additions & 9 deletions episodes/06-blurring.md
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ fig, ax = plt.subplots()
ax.imshow(image)
```

![](data/gaussian-original.png){alt='Original image'}
![](fig/gaussian-original.png){alt='Original image'}

Next, we apply the gaussian blur:

Expand Down Expand Up @@ -331,8 +331,8 @@ ax.imshow(blurred)

## Visualising Blurring

Somebody said once "an image is worth a thousand words".
What is actually happening to the image pixels when we apply blurring may be
Somebody said once "an image is worth a thousand words".
What is actually happening to the image pixels when we apply blurring may be
difficult to grasp. Let's now visualise the effects of blurring from a different
perspective.

Expand Down Expand Up @@ -430,18 +430,18 @@ but can be viewed by following the links in the captions.


![
A 3D plot of pixel intensities across the whole Petri dish image before blurring.
[Explore how this plot was created with matplotlib](https://gist.github.com/chbrandt/63ba38142630a0586ba2a13eabedf94b).
A 3D plot of pixel intensities across the whole Petri dish image before blurring.
[Explore how this plot was created with matplotlib](https://gist.github.com/chbrandt/63ba38142630a0586ba2a13eabedf94b).
Image credit: [Carlos H Brandt](https://github.com/chbrandt/).
](fig/3D_petri_before_blurring.png){
alt='3D surface plot showing pixel intensities across the whole example Petri dish image before blurring'
}

![
A 3D plot of pixel intensities after Gaussian blurring of the Petri dish image.
Note the 'smoothing' effect on the pixel intensities of the colonies in the image,
and the 'flattening' of the background noise at relatively low pixel intensities throughout the image.
[Explore how this plot was created with matplotlib](https://gist.github.com/chbrandt/63ba38142630a0586ba2a13eabedf94b).
A 3D plot of pixel intensities after Gaussian blurring of the Petri dish image.
Note the 'smoothing' effect on the pixel intensities of the colonies in the image,
and the 'flattening' of the background noise at relatively low pixel intensities throughout the image.
[Explore how this plot was created with matplotlib](https://gist.github.com/chbrandt/63ba38142630a0586ba2a13eabedf94b).
Image credit: [Carlos H Brandt](https://github.com/chbrandt/).
](fig/3D_petri_after_blurring.png){
alt='3D surface plot illustrating the smoothing effect on pixel intensities across the whole example Petri dish image after blurring'
Expand Down
Loading
Loading