Skip to content

Commit b04f15d

Browse files
back 4
1 parent d932f67 commit b04f15d

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

src/diffusers/pipelines/free_noise_utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -341,9 +341,9 @@ def _encode_prompt_free_noise(
341341
start_tensor = negative_prompt_embeds[i].unsqueeze(0)
342342
end_tensor = negative_prompt_embeds[i + 1].unsqueeze(0)
343343

344-
negative_prompt_interpolation_embeds[start_frame : end_frame + 1] = (
345-
self._free_noise_prompt_interpolation_callback(start_frame, end_frame, start_tensor, end_tensor)
346-
)
344+
negative_prompt_interpolation_embeds[
345+
start_frame : end_frame + 1
346+
] = self._free_noise_prompt_interpolation_callback(start_frame, end_frame, start_tensor, end_tensor)
347347

348348
prompt_embeds = prompt_interpolation_embeds
349349
negative_prompt_embeds = negative_prompt_interpolation_embeds

src/diffusers/pipelines/pipeline_loading_utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,9 @@ def maybe_raise_or_warn(
287287
model_cls = unwrapped_sub_model.__class__
288288

289289
if not issubclass(model_cls, expected_class_obj):
290-
raise ValueError(f"{passed_class_obj[name]} is of type: {model_cls}, but should be {expected_class_obj}")
290+
raise ValueError(
291+
f"{passed_class_obj[name]} is of type: {model_cls}, but should be" f" {expected_class_obj}"
292+
)
291293
else:
292294
logger.warning(
293295
f"You have passed a non-standard module {passed_class_obj[name]}. We cannot verify whether it"

src/diffusers/pipelines/pipeline_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1449,8 +1449,8 @@ def download(cls, pretrained_model_name, **kwargs) -> Union[str, os.PathLike]:
14491449

14501450
if load_components_from_hub and not trust_remote_code:
14511451
raise ValueError(
1452-
f"The repository for {pretrained_model_name} contains custom code in {'.py, '.join([os.path.join(k, v) for k, v in custom_components.items()])} which must be executed to correctly "
1453-
f"load the model. You can inspect the repository content at {', '.join([f'https://hf.co/{pretrained_model_name}/{k}/{v}.py' for k, v in custom_components.items()])}.\n"
1452+
f"The repository for {pretrained_model_name} contains custom code in {'.py, '.join([os.path.join(k, v) for k,v in custom_components.items()])} which must be executed to correctly "
1453+
f"load the model. You can inspect the repository content at {', '.join([f'https://hf.co/{pretrained_model_name}/{k}/{v}.py' for k,v in custom_components.items()])}.\n"
14541454
f"Please pass the argument `trust_remote_code=True` to allow custom code to be run."
14551455
)
14561456

0 commit comments

Comments
 (0)