@@ -94,6 +94,7 @@ def _cfg(url='', **kwargs):
9494 'coatnet_rmlp_0_rw_224' : _cfg (url = '' ),
9595 'coatnet_rmlp_1_rw_224' : _cfg (
9696 url = '' ),
97+ 'coatnet_nano_cc_224' : _cfg (url = '' ),
9798 'coatnext_nano_rw_224' : _cfg (url = '' ),
9899
99100 # Trying to be like the CoAtNet paper configs
@@ -105,12 +106,12 @@ def _cfg(url='', **kwargs):
105106 'coatnet_5_224' : _cfg (url = '' ),
106107
107108 # Experimental configs
108- 'maxvit_pico_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 )),
109- 'maxvit_nano_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 )),
109+ 'maxvit_pico_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 ), pool_size = ( 8 , 8 ) ),
110+ 'maxvit_nano_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 ), pool_size = ( 8 , 8 ) ),
110111 'maxvit_tiny_rw_224' : _cfg (url = '' ),
111- 'maxvit_tiny_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 )),
112- 'maxvit_tiny_cm_256' : _cfg (url = '' , input_size = (3 , 256 , 256 )),
113- 'maxxvit_nano_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 )),
112+ 'maxvit_tiny_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 ), pool_size = ( 8 , 8 ) ),
113+ 'maxvit_tiny_cm_256' : _cfg (url = '' , input_size = (3 , 256 , 256 ), pool_size = ( 8 , 8 ) ),
114+ 'maxxvit_nano_rw_256' : _cfg (url = '' , input_size = (3 , 256 , 256 ), pool_size = ( 8 , 8 ) ),
114115
115116 # Trying to be like the MaxViT paper configs
116117 'maxvit_tiny_224' : _cfg (url = '' ),
@@ -1052,7 +1053,6 @@ def __init__(
10521053 self .drop_path2 = DropPath (drop_path ) if drop_path > 0. else nn .Identity ()
10531054
10541055 def _partition_attn (self , x ):
1055- C = x .shape [- 1 ]
10561056 img_size = x .shape [1 :3 ]
10571057 if self .partition_block :
10581058 partitioned = window_partition (x , self .partition_size )
@@ -1415,6 +1415,7 @@ def __init__(
14151415 self .norm1 = norm_act_layer (out_chs [0 ])
14161416 self .conv2 = create_conv2d (out_chs [0 ], out_chs [1 ], kernel_size , stride = 1 )
14171417
1418+ @torch .jit .ignore
14181419 def init_weights (self , scheme = '' ):
14191420 named_apply (partial (_init_conv , scheme = scheme ), self )
14201421
0 commit comments