I am looking for an efficient way of detecting positive cells and running a pixelclassifier in a script. This works fine and sets every detection class to positive or negative:
selectTMACores();
runPlugin('qupath.imagej.detect.cells.PositiveCellDetection', '<big command>');
But it also detects in regions that are folds in my TMA-core. So I trained a pixel classifier that distinguishes tissue/fold/background. After this command:
def classifiers = project.getPixelClassifiers()
def classifier = classifiers.get('tissue_folds_ann_mlp')
imageData = getCurrentImageData()
PixelClassifierTools.classifyDetectionsByCentroid(imageData, classifier)
The positive/negative class is overwritten by the pixel classifier.
Is there a way to keep both?
At the moment I go over each detection after the pixelclassifier has ran and for the ones with the class ‘tissue’ I compare the DAB OD mean intensity of the cell with a threshold to redo what the celldetection already did before.
Is it possible to have more than one class?