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
195e437a
Unverified
Commit
195e437a
authored
Nov 18, 2022
by
Patrick von Platen
Committed by
GitHub
Nov 18, 2022
Browse files
Correct path to schedlure (#1322)
* [Examples] Correct path * uP
parent
fcfdd95f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
examples/dreambooth/train_dreambooth.py
examples/dreambooth/train_dreambooth.py
+1
-1
examples/text_to_image/train_text_to_image.py
examples/text_to_image/train_text_to_image.py
+2
-2
examples/textual_inversion/textual_inversion.py
examples/textual_inversion/textual_inversion.py
+2
-2
No files found.
examples/dreambooth/train_dreambooth.py
View file @
195e437a
...
@@ -472,7 +472,7 @@ def main(args):
...
@@ -472,7 +472,7 @@ def main(args):
eps
=
args
.
adam_epsilon
,
eps
=
args
.
adam_epsilon
,
)
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
"CompVis/stable-diffusion-v1-4"
,
subfolder
=
"scheduler"
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
args
.
pretrained_model_name_or_path
,
subfolder
=
"scheduler"
)
train_dataset
=
DreamBoothDataset
(
train_dataset
=
DreamBoothDataset
(
instance_data_root
=
args
.
instance_data_dir
,
instance_data_root
=
args
.
instance_data_dir
,
...
...
examples/text_to_image/train_text_to_image.py
View file @
195e437a
...
@@ -372,7 +372,7 @@ def main():
...
@@ -372,7 +372,7 @@ def main():
weight_decay
=
args
.
adam_weight_decay
,
weight_decay
=
args
.
adam_weight_decay
,
eps
=
args
.
adam_epsilon
,
eps
=
args
.
adam_epsilon
,
)
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
"CompVis/stable-diffusion-v1-4"
,
subfolder
=
"scheduler"
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
args
.
pretrained_model_name_or_path
,
subfolder
=
"scheduler"
)
# Get the datasets: you can either provide your own training and evaluation files (see below)
# Get the datasets: you can either provide your own training and evaluation files (see below)
# or specify a Dataset from the hub (the dataset will be downloaded automatically from the datasets Hub).
# or specify a Dataset from the hub (the dataset will be downloaded automatically from the datasets Hub).
...
@@ -605,7 +605,7 @@ def main():
...
@@ -605,7 +605,7 @@ def main():
vae
=
vae
,
vae
=
vae
,
unet
=
unet
,
unet
=
unet
,
tokenizer
=
tokenizer
,
tokenizer
=
tokenizer
,
scheduler
=
PNDMScheduler
.
from_config
(
"CompVis/stable-diffusion-v1-4"
,
subfolder
=
"scheduler"
),
scheduler
=
PNDMScheduler
.
from_config
(
args
.
pretrained_model_name_or_path
,
subfolder
=
"scheduler"
),
safety_checker
=
StableDiffusionSafetyChecker
.
from_pretrained
(
"CompVis/stable-diffusion-safety-checker"
),
safety_checker
=
StableDiffusionSafetyChecker
.
from_pretrained
(
"CompVis/stable-diffusion-safety-checker"
),
feature_extractor
=
CLIPFeatureExtractor
.
from_pretrained
(
"openai/clip-vit-base-patch32"
),
feature_extractor
=
CLIPFeatureExtractor
.
from_pretrained
(
"openai/clip-vit-base-patch32"
),
)
)
...
...
examples/textual_inversion/textual_inversion.py
View file @
195e437a
...
@@ -441,7 +441,7 @@ def main():
...
@@ -441,7 +441,7 @@ def main():
eps
=
args
.
adam_epsilon
,
eps
=
args
.
adam_epsilon
,
)
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
"CompVis/stable-diffusion-v1-4"
,
subfolder
=
"scheduler"
)
noise_scheduler
=
DDPMScheduler
.
from_config
(
args
.
pretrained_model_name_or_path
,
subfolder
=
"scheduler"
)
train_dataset
=
TextualInversionDataset
(
train_dataset
=
TextualInversionDataset
(
data_root
=
args
.
train_data_dir
,
data_root
=
args
.
train_data_dir
,
...
@@ -574,7 +574,7 @@ def main():
...
@@ -574,7 +574,7 @@ def main():
vae
=
vae
,
vae
=
vae
,
unet
=
unet
,
unet
=
unet
,
tokenizer
=
tokenizer
,
tokenizer
=
tokenizer
,
scheduler
=
PNDMScheduler
.
from_config
(
"CompVis/stable-diffusion-v1-4"
,
subfolder
=
"scheduler"
),
scheduler
=
PNDMScheduler
.
from_config
(
args
.
pretrained_model_name_or_path
,
subfolder
=
"scheduler"
),
safety_checker
=
StableDiffusionSafetyChecker
.
from_pretrained
(
"CompVis/stable-diffusion-safety-checker"
),
safety_checker
=
StableDiffusionSafetyChecker
.
from_pretrained
(
"CompVis/stable-diffusion-safety-checker"
),
feature_extractor
=
CLIPFeatureExtractor
.
from_pretrained
(
"openai/clip-vit-base-patch32"
),
feature_extractor
=
CLIPFeatureExtractor
.
from_pretrained
(
"openai/clip-vit-base-patch32"
),
)
)
...
...
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