Skip to content

Commit

Permalink
Updated batch processing description
Browse files Browse the repository at this point in the history
  • Loading branch information
jhennies committed Jul 18, 2024
1 parent 98985c4 commit 6a6785d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
5 changes: 4 additions & 1 deletion _includes/batch_processing/batch_measure_nuclei_shape.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@
# Create a function that analyses one image
# Below, this function will be called several times, for all images
def analyse(image_path, output_folder):

# This prints which image is currently analysed
print("Analyzing:", image_path)

image, axes, scales, units = open_ij_tiff(image_path)

# Binarize the image using auto-thresholding
Expand Down Expand Up @@ -67,7 +71,6 @@ def analyse(image_path, output_folder):
"https://github.com/NEUBIAS/training-resources/raw/master/image_data/xy_8bit__mitocheck_incenp_t70.tif"]

for image_path in image_paths:
print("Analyzing:", image_path)
analyse(image_path, output_dir)

# %%
Expand Down
13 changes: 13 additions & 0 deletions _includes/batch_processing/batch_measure_nuclei_shapes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,16 @@

- In a previous module [there is a workflow to measure the shapes of nuclei in one image](https://neubias.github.io/training-resources/workflow_segment_2d_nuclei_measure_shape/index.html#2dnuclei)
- Adapt this workflow for automated batch analysis of many images
- Start by building the skeleton of the workflow without filling in the functionality;

Note that the code below runs fine, but does not produce any results:

```
def analyse(image_path, output_folder):
print("Analyzing:", image_path)
for image_path in image_paths:
analyse(image_path, output_dir)
```

- Make sure the loop with the (almost) empty analyse function runs without error before filling in the image analysis steps

0 comments on commit 6a6785d

Please sign in to comment.