Merge branch 'comfyanonymous:master' into latent_preview_api

This commit is contained in:
RandomGitUser321 2024-09-20 02:44:45 -04:00 committed by GitHub
commit b238afd0f8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -414,7 +414,7 @@ def calculate_weight(patches, weight, key, intermediate_dtype=torch.float32):
weight *= strength_model weight *= strength_model
if isinstance(v, list): if isinstance(v, list):
v = (calculate_weight(v[1:], v[0].clone(), key, intermediate_dtype=intermediate_dtype), ) v = (calculate_weight(v[1:], comfy.model_management.cast_to_device(v[0], weight.device, intermediate_dtype, copy=True), key, intermediate_dtype=intermediate_dtype), )
if len(v) == 1: if len(v) == 1:
patch_type = "diff" patch_type = "diff"