Fix test_auto_backbone_timm_model_from_pretrained (#34877)

fix

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
This commit is contained in:
Yih-Dar
2024-11-25 17:20:41 +01:00
committed by GitHub
parent a464afbe2a
commit a830df2909

View File

@@ -239,7 +239,7 @@ class AutoModelTest(unittest.TestCase):
# Check kwargs are correctly passed to the backbone # Check kwargs are correctly passed to the backbone
model = AutoBackbone.from_pretrained("resnet18", use_timm_backbone=True, out_indices=(-2, -1)) model = AutoBackbone.from_pretrained("resnet18", use_timm_backbone=True, out_indices=(-2, -1))
self.assertEqual(model.out_indices, (-2, -1)) self.assertEqual(model.out_indices, [-2, -1])
# Check out_features cannot be passed to Timm backbones # Check out_features cannot be passed to Timm backbones
with self.assertRaises(ValueError): with self.assertRaises(ValueError):