imagej / pyimagej

Use ImageJ from Python
https://pyimagej.readthedocs.io/
Other
473 stars 82 forks source link

A bug in the Use cases"Classic Segmentation: Segmentation workflow with original ImageJ functions" in PyImageJ’s documentation #282

Closed mol666 closed 1 year ago

mol666 commented 1 year ago

There are 32 cells detected, however the output has 32 group of datas which are completely same. They are just the measurements of the first cell. This line of code: for column in results.getHeadings(): stats_ij[column].append(results.getColumn(column)[0]) should be modified to be: stats_ij[column].append(results.getColumn(column)[-1]) as the index while appending should be corrected.

Hope some notice.

elevans commented 1 year ago

Hi @mol666, thanks for pointing this out! You are correct, we had the wrong output here. I'm pretty close to finishing a PR that will bring some updates to the documentation (either today or tomorrow). I will be sure to include this into https://github.com/imagej/pyimagej/pull/276. For now I'll keep this issue open until I get that merged into main.

mol666 commented 1 year ago

That's great! PyimageJ and what you developers do help me a lot. Sincere thanks to you!

elevans commented 1 year ago

This fix as been merged into main: e50446ec204951dacd56605666191c60e33ff8df.