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
610a71d7
Unverified
Commit
610a71d7
authored
Jul 02, 2024
by
Dhruv Nair
Committed by
GitHub
Jul 02, 2024
Browse files
Fix indent in dreambooth lora advanced SD 15 script (#8753)
update
parent
c104482b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
examples/advanced_diffusion_training/train_dreambooth_lora_sd15_advanced.py
...diffusion_training/train_dreambooth_lora_sd15_advanced.py
+4
-5
No files found.
examples/advanced_diffusion_training/train_dreambooth_lora_sd15_advanced.py
View file @
610a71d7
...
@@ -1856,10 +1856,10 @@ def main(args):
...
@@ -1856,10 +1856,10 @@ def main(args):
generator
=
torch
.
Generator
(
device
=
accelerator
.
device
).
manual_seed
(
args
.
seed
)
if
args
.
seed
else
None
generator
=
torch
.
Generator
(
device
=
accelerator
.
device
).
manual_seed
(
args
.
seed
)
if
args
.
seed
else
None
pipeline_args
=
{
"prompt"
:
args
.
validation_prompt
}
pipeline_args
=
{
"prompt"
:
args
.
validation_prompt
}
if
torch
.
backends
.
mps
.
is_available
():
if
torch
.
backends
.
mps
.
is_available
():
autocast_ctx
=
nullcontext
()
autocast_ctx
=
nullcontext
()
else
:
else
:
autocast_ctx
=
torch
.
autocast
(
accelerator
.
device
.
type
)
autocast_ctx
=
torch
.
autocast
(
accelerator
.
device
.
type
)
with
autocast_ctx
:
with
autocast_ctx
:
images
=
[
images
=
[
...
@@ -1880,7 +1880,6 @@ def main(args):
...
@@ -1880,7 +1880,6 @@ def main(args):
]
]
}
}
)
)
del
pipeline
del
pipeline
torch
.
cuda
.
empty_cache
()
torch
.
cuda
.
empty_cache
()
...
...
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