Skip to content

Commit e828793

Browse files
authored
Merge branch 'main' into sd_gligen
2 parents d45e7f3 + 0967593 commit e828793

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/diffusers/loaders/lora_pipeline.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2313,7 +2313,7 @@ def _maybe_expand_transformer_param_shape_or_error_(
23132313
for name, module in transformer.named_modules():
23142314
if isinstance(module, torch.nn.Linear):
23152315
module_weight = module.weight.data
2316-
module_bias = module.bias.data if hasattr(module, "bias") else None
2316+
module_bias = module.bias.data if module.bias is not None else None
23172317
bias = module_bias is not None
23182318

23192319
lora_A_weight_name = f"{name}.lora_A.weight"

0 commit comments

Comments
 (0)