mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-03-17 07:05:12 +08:00
ops: dont discard pins
Its more likely that the user will rerun their workflow and want whatever pins are inplace so remove this. pins still have to respect RAM pressure per model anyway.
This commit is contained in:
parent
04141efe54
commit
cd085314f9
@ -131,11 +131,7 @@ def cast_bias_weight_with_vbar(s, dtype, device, bias_dtype, non_blocking, compu
|
||||
xfer_dest = cast_dest
|
||||
|
||||
pin = None
|
||||
if signature is not None:
|
||||
#If we are able to increase our load level (e.g. user reduces resolution or batch number)
|
||||
#reclaim the pin previously used for offload.
|
||||
comfy.pinned_memory.unpin_memory(s)
|
||||
elif not resident:
|
||||
if signature is None and not resident:
|
||||
#prepare a new pin
|
||||
assert comfy.pinned_memory.get_pin(s) is None
|
||||
comfy.pinned_memory.pin_memory(s)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user