mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-01-11 14:50:49 +08:00
Fix model measurements to call
This commit is contained in:
parent
537e34358f
commit
67432bee6c
@ -287,9 +287,9 @@ class MemoryMeasurements:
|
|||||||
@device.setter
|
@device.setter
|
||||||
def device(self, value: torch.device):
|
def device(self, value: torch.device):
|
||||||
if isinstance(self.model, DeviceSettable):
|
if isinstance(self.model, DeviceSettable):
|
||||||
|
# todo: is this correct?
|
||||||
self.model.device = value
|
self.model.device = value
|
||||||
elif hasattr(self.model, "to"):
|
# todo: we don't want to `to` anything anymore here
|
||||||
self.model.to(value)
|
|
||||||
self._device = value
|
self._device = value
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user