55
55
# transformer models don't support many of the spatial / feature based model functionalities
56
56
NON_STD_FILTERS = [
57
57
'vit_*' , 'tnt_*' , 'pit_*' , 'coat_*' , 'cait_*' , '*mixer_*' , 'gmlp_*' , 'resmlp_*' , 'twins_*' ,
58
- 'convit_*' , 'levit*' , 'visformer*' , 'deit*' , 'jx_nest_*' , 'nest_*' , ' xcit_*' , 'crossvit_*' , 'beit*' ,
59
- 'poolformer_*' , 'volo_*' , 'sequencer2d_*' , 'pvt_v2*' , ' mvitv2*' , 'gcvit*' , 'efficientformer*' ,
58
+ 'convit_*' , 'levit*' , 'visformer*' , 'deit*' , 'xcit_*' , 'crossvit_*' , 'beit*' ,
59
+ 'poolformer_*' , 'volo_*' , 'sequencer2d_*' , 'mvitv2*' , 'gcvit*' , 'efficientformer*' ,
60
60
'eva_*' , 'flexivit*' , 'eva02*' , 'samvit_*' , 'efficientvit_m*' , 'tiny_vit_*'
61
61
]
62
62
NUM_NON_STD = len (NON_STD_FILTERS )
@@ -356,15 +356,15 @@ def test_model_forward_torchscript(model_name, batch_size):
356
356
357
357
@pytest .mark .features
358
358
@pytest .mark .timeout (120 )
359
- @pytest .mark .parametrize ('model_name' , list_models (exclude_filters = EXCLUDE_FILTERS + EXCLUDE_FEAT_FILTERS , include_tags = True ))
359
+ @pytest .mark .parametrize ('model_name' , list_models (exclude_filters = EXCLUDE_FILTERS + EXCLUDE_FEAT_FILTERS ))
360
360
@pytest .mark .parametrize ('batch_size' , [1 ])
361
361
def test_model_forward_features (model_name , batch_size ):
362
362
"""Run a single forward pass with each model in feature extraction mode"""
363
363
model = create_model (model_name , pretrained = False , features_only = True )
364
364
model .eval ()
365
365
expected_channels = model .feature_info .channels ()
366
366
expected_reduction = model .feature_info .reduction ()
367
- assert len (expected_channels ) >= 4 # all models here should have at least 4 feature levels by default, some 5 or 6
367
+ assert len (expected_channels ) >= 3 # all models here should have at least 3 default feat levels
368
368
369
369
input_size = _get_input_size (model = model , target = TARGET_FFEAT_SIZE )
370
370
if max (input_size ) > MAX_FFEAT_SIZE :
@@ -387,7 +387,7 @@ def test_model_forward_features(model_name, batch_size):
387
387
388
388
@pytest .mark .features
389
389
@pytest .mark .timeout (120 )
390
- @pytest .mark .parametrize ('model_name' , list_models (FEAT_INTER_FILTERS , include_tags = True ))
390
+ @pytest .mark .parametrize ('model_name' , list_models (FEAT_INTER_FILTERS , exclude_filters = EXCLUDE_FILTERS ))
391
391
@pytest .mark .parametrize ('batch_size' , [1 ])
392
392
def test_model_forward_intermediates_features (model_name , batch_size ):
393
393
"""Run a single forward pass with each model in feature extraction mode"""
@@ -419,7 +419,7 @@ def test_model_forward_intermediates_features(model_name, batch_size):
419
419
420
420
@pytest .mark .features
421
421
@pytest .mark .timeout (120 )
422
- @pytest .mark .parametrize ('model_name' , list_models (FEAT_INTER_FILTERS , include_tags = True ))
422
+ @pytest .mark .parametrize ('model_name' , list_models (FEAT_INTER_FILTERS , exclude_filters = EXCLUDE_FILTERS ))
423
423
@pytest .mark .parametrize ('batch_size' , [1 ])
424
424
def test_model_forward_intermediates (model_name , batch_size ):
425
425
"""Run a single forward pass with each model in feature extraction mode"""
0 commit comments