Browse Source
fix config type caused by timm version
Signed-off-by: ChengZi <chen.zhang@zilliz.com>
main
ChengZi
2 years ago
1 changed files with
2 additions and
0 deletions
-
isc.py
|
@ -128,6 +128,8 @@ class Isc(NNOperator): |
|
|
@property |
|
|
@property |
|
|
def config(self): |
|
|
def config(self): |
|
|
config = get_pretrained_cfg(self.timm_backbone) |
|
|
config = get_pretrained_cfg(self.timm_backbone) |
|
|
|
|
|
if hasattr(config, 'to_dict'): |
|
|
|
|
|
config = config.to_dict() |
|
|
return config |
|
|
return config |
|
|
|
|
|
|
|
|
def save_model(self, format: str = 'pytorch', path: str = 'default'): |
|
|
def save_model(self, format: str = 'pytorch', path: str = 'default'): |
|
|