Stardist in KNIME

Hi @stelfrich,

I have tried to run your Stardist2D component in KNIME and I followed the installation instructions here: StarDist or Noise2Voide from KNIME .
But I run into the following error: “Execute failed: Cleaning Up;3:454:0:127: Insert Column Header 3:454:0:127:90: No name assignment for column “label” – set the appropriate option in the configuration dialog to keep the original column name.”

I can run your example using the worklfow here: CSBDeep_StarDist – KNIME Hub , but with my 2048x2048 image it runs into an input shape issue during a concatenation step (ConcatOp : Dimensions of inputs should match: shape[0] = [1,128,124,124] vs. shape[1] = [1,128,125,125])

What would be the best way to get stardist running for my images in KNIME?

BTW I joined the NEUBIAS KNIME workshop last week and it was great, thanks!

Best,

Chris

3 Likes

Hi @chrisdinant,

This sounds like there is an issue with an additional column in one of the output tables. Sorry for asking the obvious: Did you really get the StarDist_-0.3.0-all.jar from the Google Drive linked in the other thread? Also, how does the table look like before passing it to the component, i.e. which columns does it contain and how did you configure the component?

There’s a side branch in this example workflow for cropping of images to the appropriate sizes: 2048 by 2048 sounds correct, though. Still, copy the nodes of the side branch into your workflow and give it a try to see what happens…

Best,
Stefan

1 Like

Thanks a lot @stelfrich,

The image shape was a mistake on my side. It was a 1000x1000 image. With your cropper module it works fine.

I haven’t figured out the extra column issue yet. I just run your Stardist example workflow StarDist Example – KNIME Hub straight out of the box and it gives the column error I mentioned. I saw there was an update in the workflow Yesterday, but it still gives the same error for me.
I also tried to delete the second channel from your example image, so a table with just a Row ID and “nuclei” column (the image) into the Stardist2D component but it still comes with the same error.

Best,

Chris

Interesting. I just re-downloaded the workflow and it ran without any problems. Could you open the StarDist 2D component, open up the Cleaning Up metanode and paste the column names of the StarDist 2D NMS (postprocessing only) node in here? Thank you!

Best,
Stefan

The output (Processed Images) of StarDist 2D NMS (postprocessing only) is a “Row ID” and “label” column.
The Constant Value Column node has “labelImg” in the “Output Column Name” column. Could the problem be that “Insert Column Header” is looking for “labelImg” and it finds “label” instead?
I am very much a beginner here, so I don’t know how to make these nodes editable and change it myself.

That’s the culprit right there: This should return a column that is called labelImg and I would really like to figure out why that is happening. Did you, by chance, change the preferences in File > Preferences > KNIME > Image Processing Plugin > ImageJ1 Preferences to point to your Fiji installation? Also, did you make any additional changes to the ImageJ2 Plugin Installation preferences?

My ImageJ1 preferences points to “E:\Program Files\KNIME\plugins\org.knime.knip.imagej1_0.11.7.v202007071306\plugins” and my ImageJ2 Plugin Install has only the StarDist_-0.3.0-all file listed and the “selected knime\plugins directory:” entry is “E:\Program Files\KNIME\plugins”. Other than installing the Image Processing and deep learning tools I made no other changes anywhere else in KNIME that I can think of (I just installed it three days ago).