I am probably missing something obvious but is there a best/most efficient way to calculate image segment features (intensities) of three channels simultaneously?
three parallel executions of the image segment features node with a different input for each of the three channels, then join the outputs?
I’d say both is possible, and it depends on your actual use case.
If you know you’ll always have three channels in your datasets, then it might be fine to “hardcode” it by using three Image Segment Features nodes, each one configured for one of the split channels.
In this case, it might however be more performant to re-shape the table so that all channels are in the same column. You can do this using the Unpivoting – KNIME Hub node.
If you have a lot of image datasets (i.e. a lot of table rows), it usually makes more sense to parallelize on a higher level (i.e. parallelize all the input rows with the Parallel Chunk nodes) and then keep the workflow part that deals with each image more or less sequential.
To compare how the different approaches perform on your own data, you can use Timer Info – KNIME Hub and look at the added times of all nodes concerned.
I am finally getting around to implementing the options mentioned above.
Hard coding works but it looks a bit messy as many nodes are used. Second place for processing time.
Unpivoting works but the column names are lost in the Feature Calculator (Beta) node. By the time that I have manipulated the rowIDs to re-generate that information, things are looking messy again. This is the quickest in terms of processing time.
Looping the columns looks the cleanest but takes the longest.
The test data set that I am using is small and the processing is pre-faced with a Cellpose segmentation node which takes much longer than the couple of seconds to measure segment features.