mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2025-12-12 15:35:00 +08:00
ops: Put weight cast on the offload stream (#10697)
This needs to be on the offload stream. This reproduced a black screen with low resolution images on a slow bus when using FP8.
This commit is contained in:
parent
dea899f221
commit
c350009236
@ -110,9 +110,9 @@ def cast_bias_weight(s, input=None, dtype=None, device=None, bias_dtype=None, of
|
|||||||
for f in s.bias_function:
|
for f in s.bias_function:
|
||||||
bias = f(bias)
|
bias = f(bias)
|
||||||
|
|
||||||
weight = weight.to(dtype=dtype)
|
if weight_has_function or weight.dtype != dtype:
|
||||||
if weight_has_function:
|
|
||||||
with wf_context:
|
with wf_context:
|
||||||
|
weight = weight.to(dtype=dtype)
|
||||||
for f in s.weight_function:
|
for f in s.weight_function:
|
||||||
weight = f(weight)
|
weight = f(weight)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user