Skip to content

Commit f62527f

Browse files
committed
remove comment
1 parent ac420af commit f62527f

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

src/diffusers/models/model_loading_utils.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -343,11 +343,9 @@ def _merge_sharded_checkpoints(
343343
for file_name in files_to_load:
344344
part_file_path = os.path.join(sharded_ckpt_cached_folder, file_name)
345345
if dduf_entries:
346-
# If dduf_entries is provided, check if part_file_path is in it
347346
if part_file_path not in dduf_entries:
348347
raise FileNotFoundError(f"Part file {file_name} not found.")
349348
else:
350-
# If dduf_entries is not provided, check if the file exists on disk
351349
if not os.path.exists(part_file_path):
352350
raise FileNotFoundError(f"Part file {file_name} not found.")
353351

src/diffusers/utils/hub_utils.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,11 +450,9 @@ def _get_checkpoint_shard_files(
450450
index (downloaded and cached if `pretrained_model_name_or_path` is a model ID on the Hub).
451451
"""
452452
if dduf_entries:
453-
# If dduf_entries is provided, check if part_file_path is in it
454453
if index_filename not in dduf_entries:
455454
raise ValueError(f"Can't find a checkpoint index ({index_filename}) in {pretrained_model_name_or_path}.")
456455
else:
457-
# If dduf_entries is not provided, check if the file exists on disk
458456
if not os.path.isfile(index_filename):
459457
raise ValueError(f"Can't find a checkpoint index ({index_filename}) in {pretrained_model_name_or_path}.")
460458

0 commit comments

Comments
 (0)