Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
renzhc
diffusers_dcu
Commits
0d4b459b
Unverified
Commit
0d4b459b
authored
Oct 26, 2023
by
nickkolok
Committed by
GitHub
Oct 26, 2023
Browse files
Update train_dreambooth.py - fix typos (#5539)
parent
cee1cd6e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
examples/dreambooth/train_dreambooth.py
examples/dreambooth/train_dreambooth.py
+2
-2
No files found.
examples/dreambooth/train_dreambooth.py
View file @
0d4b459b
...
@@ -1167,7 +1167,7 @@ def main(args):
...
@@ -1167,7 +1167,7 @@ def main(args):
if
args
.
resume_from_checkpoint
!=
"latest"
:
if
args
.
resume_from_checkpoint
!=
"latest"
:
path
=
os
.
path
.
basename
(
args
.
resume_from_checkpoint
)
path
=
os
.
path
.
basename
(
args
.
resume_from_checkpoint
)
else
:
else
:
# Get the mos recent checkpoint
# Get the mos
t
recent checkpoint
dirs
=
os
.
listdir
(
args
.
output_dir
)
dirs
=
os
.
listdir
(
args
.
output_dir
)
dirs
=
[
d
for
d
in
dirs
if
d
.
startswith
(
"checkpoint"
)]
dirs
=
[
d
for
d
in
dirs
if
d
.
startswith
(
"checkpoint"
)]
dirs
=
sorted
(
dirs
,
key
=
lambda
x
:
int
(
x
.
split
(
"-"
)[
1
]))
dirs
=
sorted
(
dirs
,
key
=
lambda
x
:
int
(
x
.
split
(
"-"
)[
1
]))
...
@@ -1364,7 +1364,7 @@ def main(args):
...
@@ -1364,7 +1364,7 @@ def main(args):
if
global_step
>=
args
.
max_train_steps
:
if
global_step
>=
args
.
max_train_steps
:
break
break
# Create the pipeline using
using
the trained modules and save it.
# Create the pipeline using the trained modules and save it.
accelerator
.
wait_for_everyone
()
accelerator
.
wait_for_everyone
()
if
accelerator
.
is_main_process
:
if
accelerator
.
is_main_process
:
pipeline_args
=
{}
pipeline_args
=
{}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment