Fix post_process_semantic_segmentation removing valid class in Conditional DETR
Description: Fixes #42679 What does this PR do? Conditional DETR does not have a null class unlike DETR (its classifier outputs num_labels classes, not num_labels + 1). However, the post_process_semantic_segmentation method was incorrectly applying [..., :-1] to remove what it assumed was a null class, which actually removed the last valid class. This PR removes the incorrect slice in both: image_processing_conditional_detr.py image_processing_conditional_detr_fast.py
[For maintainers] Suggested jobs to run (before merge)
run-slow: conditional_detr
I'm mainly curious here why Conditional DETR has a post_process_semantic_segmentation method, cause the only pre-trained checkpoints shared are for object detection. Otherwise it looks good to me.
yes I also checked in the docs we only have randomly initialized model + in the paper there's none either, maybe it's for random head initialization with a backbone