Skip to content

Commit

Permalink
Merge pull request #2127 from bmaltais/dev
Browse files Browse the repository at this point in the history
v23.0.13
  • Loading branch information
bmaltais committed Mar 19, 2024
2 parents 726f5b3 + c96cdf2 commit 95112e9
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .release
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v23.0.12
v23.0.13
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ The GUI allows you to set the training parameters and generate and run the requi
- [No module called tkinter](#no-module-called-tkinter)
- [SDXL training](#sdxl-training)
- [Change History](#change-history)
- [2024/03/13 (v23.0.13)](#20240313-v23013)
- [2024/03/16 (v23.0.12)](#20240316-v23012)
- [New Features \& Improvements](#new-features--improvements)
- [Software Updates](#software-updates)
Expand Down Expand Up @@ -379,6 +380,10 @@ The documentation in this section will be moved to a separate document later.
## Change History
### 2024/03/13 (v23.0.13)
- Fix issue with image samples.
### 2024/03/16 (v23.0.12)
#### New Features & Improvements
Expand Down
12 changes: 9 additions & 3 deletions kohya_gui/class_sample_images.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,13 @@ def run_cmd_sample(

run_cmd = ''

if sample_every_n_epochs == sample_every_n_steps == '0':
if sample_every_n_epochs is None:
sample_every_n_epochs = 0

if sample_every_n_steps is None:
sample_every_n_steps = 0

if sample_every_n_epochs == sample_every_n_steps == 0:
return run_cmd

# Create the prompt file and get its path
Expand All @@ -55,10 +61,10 @@ def run_cmd_sample(
run_cmd += f' --sample_sampler={sample_sampler}'
run_cmd += f' --sample_prompts="{sample_prompts_path}"'

if sample_every_n_epochs != '0':
if sample_every_n_epochs != 0:
run_cmd += f' --sample_every_n_epochs={sample_every_n_epochs}'

if sample_every_n_steps != '0':
if sample_every_n_steps != 0:
run_cmd += f' --sample_every_n_steps={sample_every_n_steps}'

return run_cmd
Expand Down

0 comments on commit 95112e9

Please sign in to comment.