MCPcopy Index your code
hub / github.com/modelscope/DiffSynth-Studio / onload

Method onload

diffsynth/vram_management/layers.py:25–28  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

23 self.state = 0
24
25 def onload(self):
26 if self.state != 1:
27 self.to(dtype=self.onload_dtype, device=self.onload_device)
28 self.state = 1
29
30 def keep(self):
31 if self.state != 2:

Callers 2

load_models_to_deviceMethod · 0.80
load_models_to_deviceMethod · 0.80

Calls 1

toMethod · 0.45

Tested by

no test coverage detected