As naturally open class detection models, Paligemma-2 models need a special evaluation protocol for a closed-set detection benchmark like COCO2017.
<locXXXX><locXXXX><locXXXX><locXXXX> class_string ;
class_string matches one of the classes c1,…,c_{classes_per_call}class_string may consist of multiple tokensclass_stringclasses_per_call: 5
The total of 80 COCO2017 classes are divided into 16 groups by 5.
detect person ; bicycle ; car ; motorcycle ; airplane\ndetect bus ; train ; truck ; boat ; traffic light\ndetect fire hydrant ; stop sign ; parking meter ; bench ; bird\ndetect vase ; scissors ; teddy bear ; hair drier ; toothbrush\nAll predictions (e.g. <loc0001><loc0123><loc0530><loc1012> stop sign) are then extracted
from all the 16 model outputs (which can naturally be imperfect and of arbitrary length).
Class scores (e.g. for class stop sign) are calculated as geometric mean of generation probabilities
of tokens in stop sign (e.g. a token for stop and a token for ` sign`).
In practice scores parsing implementation is a bit more complex because on the one hand it has to account for generation imperfections
(e.g. <loc0001><loc0123><loc0530><loc1012> truck ; <loc0031><loc0900><loc0127><loc1000> ; - with no class predicted for the second bounding box), structure breaks etc.
On the other hand the tokenizer itself may have its own rules set affecting the way how class_string
will be split into tokens and how their scores must be extracted.
There is a number of interesting questions related to how Paligemma-2 models perform on object detection task. In the present work we’ll try to find answers to them.
classes_per_call value affect the quality of detection?mix series of Paligemma-2 models compare to the pt series?In all cases the COCO2017 validation mAP@[IoU=0.50:0.95] is used as object detection quality assessment metric.
According to the official blog, “pt checkpoints are meant to be fine-tuned on a downstream task and were released for that purpose”, whereas “the mix models give a quick idea of the performance one would get when fine-tuning the pre-trained checkpoints on a downstream task”.



mix models appear to be more verbose than pt modelspt models peaks at classes_per_call=1 whereas for mix models, it peaks at classes_per_call=10classes_per_call increases, there is a tendency for model verbosity to grow
classes_per_call becomes more difficult for model to process, which leads to an increased risk of false positives and undetected objectsclasses_per_call a lot of predictions are duplicated (the spread before/after NMS explodes)Model is usually pretty sure about the predicted classes as the 10th quantile is at 0.82 and the 20th is at 0.96.

classes_per_call approaches 8, the 10b-pt-224 produces too many false positives (especially smaller objects), which degrades the metric
10b-pt-896 detects uniformly more smaller objects than 10b-pt-448 without significant performance degradation
28B-pt-448 model performs poorly on object detection task
10b-448 model performs slightly better than the 3b-448 model