diff --git a/tests/pipelines/test_pipelines_image_segmentation.py b/tests/pipelines/test_pipelines_image_segmentation.py index 4b88bdc0412e..1884682ec535 100644 --- a/tests/pipelines/test_pipelines_image_segmentation.py +++ b/tests/pipelines/test_pipelines_image_segmentation.py @@ -147,7 +147,6 @@ def test_small_model_tf(self): pass @require_torch - @unittest.skip("Test is broken, fix me please!") def test_small_model_pt(self): model_id = "hf-internal-testing/tiny-detr-mobilenetsv3-panoptic" @@ -165,12 +164,12 @@ def test_small_model_pt(self): [ { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, ], @@ -193,24 +192,24 @@ def test_small_model_pt(self): [ { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, ], [ { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, { "score": 0.004, - "label": "LABEL_0", + "label": "LABEL_215", "mask": "34eecd16bbfb0f476083ef947d81bf66", }, ], diff --git a/tests/pipelines/test_pipelines_object_detection.py b/tests/pipelines/test_pipelines_object_detection.py index 1a3065fdcd0a..538f31315157 100644 --- a/tests/pipelines/test_pipelines_object_detection.py +++ b/tests/pipelines/test_pipelines_object_detection.py @@ -105,7 +105,6 @@ def test_small_model_tf(self): pass @require_torch - @unittest.skip("Test is broken, fix me please!") def test_small_model_pt(self): model_id = "hf-internal-testing/tiny-detr-mobilenetsv3" @@ -118,8 +117,8 @@ def test_small_model_pt(self): self.assertEqual( nested_simplify(outputs, decimals=4), [ - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, ], ) @@ -135,12 +134,12 @@ def test_small_model_pt(self): nested_simplify(outputs, decimals=4), [ [ - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, ], [ - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, - {"score": 0.3432, "label": "LABEL_0", "box": {"xmin": 160, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, + {"score": 0.3376, "label": "LABEL_0", "box": {"xmin": 159, "ymin": 120, "xmax": 480, "ymax": 359}}, ], ], )