Skip to content

Commit

Permalink
Use sortable image filenames for SD outputs. (#1528)
Browse files Browse the repository at this point in the history
  • Loading branch information
monorimet authored Jul 3, 2023
1 parent 1c32915 commit d63ce76
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions apps/stable_diffusion/src/utils/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -755,9 +755,7 @@ def save_output_img(output_img, img_seed, extra_info={}):
csv_path = Path(generated_imgs_path, "imgs_details.csv")

prompt_slice = re.sub("[^a-zA-Z0-9]", "_", args.prompts[0][:15])
out_img_name = (
f"{prompt_slice}_{img_seed}_{dt.now().strftime('%y%m%d_%H%M%S')}"
)
out_img_name = f"{dt.now().strftime('%H%M%S')}_{prompt_slice}_{img_seed}"

img_model = args.hf_model_id
if args.ckpt_loc:
Expand Down

0 comments on commit d63ce76

Please sign in to comment.