MCPcopy Create free account
hub / github.com/UX-Decoder/Semantic-SAM / save_pretrained

Method save_pretrained

semantic_sam/BaseModel.py:22–23  ·  view source on GitHub ↗
(self, save_path)

Source from the content-addressed store, hash-verified

20 return outputs
21
22 def save_pretrained(self, save_path):
23 torch.save(self.model.state_dict(), save_path)
24
25 def from_pretrained(self, load_dir):
26 state_dict = torch.load(load_dir, map_location='cpu')

Callers

nothing calls this directly

Calls 1

saveMethod · 0.80

Tested by

no test coverage detected