logo
Browse Source

Fix issue for config

Signed-off-by: Jael Gu <mengjia.gu@zilliz.com>
main
Jael Gu 2 years ago
parent
commit
8da18d800a
  1. 11
      timm_image.py

11
timm_image.py

@ -117,7 +117,7 @@ class TimmImage(NNOperator):
@property @property
def config(self): def config(self):
return resolve_data_config({}, model=self.model)
return resolve_data_config({}, model=self._model)
@arg(1, to_image_color('RGB')) @arg(1, to_image_color('RGB'))
def convert_img(self, img: towhee._types.Image): def convert_img(self, img: towhee._types.Image):
@ -195,14 +195,7 @@ class TimmImage(NNOperator):
'crossvit_base_240', 'crossvit_base_240',
'crossvit_small_240', 'crossvit_small_240',
'crossvit_tiny_240', 'crossvit_tiny_240',
'tresnet_l',
'tresnet_l_448',
'tresnet_m',
'tresnet_m_448',
'tresnet_m_miil_in21k',
'tresnet_v2_l',
'tresnet_xl',
'tresnet_xl_448']
]
assert set(to_remove).issubset(set(full_list)) assert set(to_remove).issubset(set(full_list))
model_list = list(set(full_list) - set(to_remove)) model_list = list(set(full_list) - set(to_remove))
elif format == 'onnx': elif format == 'onnx':

Loading…
Cancel
Save