Skip to content

Commit

Permalink
Update model validation code
Browse files Browse the repository at this point in the history
  • Loading branch information
bmaltais committed May 7, 2024
1 parent 39293d3 commit 5984c87
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions kohya_gui/common_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -1420,10 +1420,8 @@ def validate_model_path(pretrained_model_name_or_path: str) -> bool:
log.info(f"{msg} SUCCESS")
else:
# If not one of the default models, check if it's a valid local path
if not os.path.exists(pretrained_model_name_or_path):
log.error(f"{msg} FAILED: is missing or does not exist")
if not validate_file_path(pretrained_model_name_or_path):
return False
log.info(f"{msg} SUCCESS")

return True

Expand Down

0 comments on commit 5984c87

Please sign in to comment.