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
c62b3a2e
Unverified
Commit
c62b3a2e
authored
Nov 04, 2022
by
Duong A. Nguyen
Committed by
GitHub
Nov 04, 2022
Browse files
[Flax] Fix sample batch size DreamBooth (#1129)
fix sample batch size
parent
bde4880c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
examples/dreambooth/train_dreambooth_flax.py
examples/dreambooth/train_dreambooth_flax.py
+2
-1
No files found.
examples/dreambooth/train_dreambooth_flax.py
View file @
c62b3a2e
...
...
@@ -361,7 +361,8 @@ def main():
logger
.
info
(
f
"Number of class images to sample:
{
num_new_images
}
."
)
sample_dataset
=
PromptDataset
(
args
.
class_prompt
,
num_new_images
)
sample_dataloader
=
torch
.
utils
.
data
.
DataLoader
(
sample_dataset
,
batch_size
=
args
.
sample_batch_size
)
total_sample_batch_size
=
args
.
sample_batch_size
*
jax
.
local_device_count
()
sample_dataloader
=
torch
.
utils
.
data
.
DataLoader
(
sample_dataset
,
batch_size
=
total_sample_batch_size
)
for
example
in
tqdm
(
sample_dataloader
,
desc
=
"Generating class images"
,
disable
=
not
jax
.
process_index
()
==
0
...
...
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