In the script it looks like the stains (collectively) have the same name as one of the stains… and another stain is called ‘-’. I can’t think of a reason why this would cause a problem, although probably best to avoid weird naming schemes while trying to figure out what is wrong.
If the problem doesn’t arise when using the default names of hematoxylin and DAB that would be good to know.
@K.massy a script generated from the full workflow (as @Research_Associate suggested above) that includes the detection would be helpful, rather than only the bit from before running the cell detection interactively. I am still having trouble following exactly what steps you apply when you see the issue, since when you listed all of them you said the problem didn’t occur… and it was only later that it reoccurred. I don’t know what exactly happened in between.
The best thing would be if you could show the problem occurs when you run a script only, with no additional steps involved.
It’s also not totally clear to me from your last answer: the problem happens both when you set the threshold during cell detection, and when you apply it later using
Finally, because the selected cell is yellow in the screenshot and the classification is obscured by the cell detection dialog, I can’t tell how it has been classified from the image. Moving the dialog out of the way or turning off the ‘Use selected color’ preference would resolve this.
QuPath’s code indicates that the threshold is applied using the measurements in the measurement list (here) - which are the same as the measurements displayed on screen - so I find it very mysterious.
I don’t feel I can make any new release of the software until understanding whether this is a bug that needs fixed urgently, or if there is some other reason why it’s happening - so I’m keen to get the bottom of it quickly.