MCPcopy
hub / github.com/huggingface/pytorch-image-models / to_dict

Method to_dict

timm/models/_pretrained.py:61–66  ·  view source on GitHub ↗
(self, remove_source=False, remove_null=True)

Source from the content-addressed store, hash-verified

59 return self.url or self.file or self.hf_hub_id
60
61 def to_dict(self, remove_source=False, remove_null=True):
62 return filter_pretrained_cfg(
63 asdict(self),
64 remove_source=remove_source,
65 remove_null=remove_null
66 )
67
68
69def filter_pretrained_cfg(cfg, remove_source=False, remove_null=True):

Callers 1

build_model_with_cfgFunction · 0.80

Calls 1

filter_pretrained_cfgFunction · 0.85

Tested by

no test coverage detected