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
5c21d962
Unverified
Commit
5c21d962
authored
Jun 13, 2022
by
Patrick von Platen
Committed by
GitHub
Jun 13, 2022
Browse files
Update README.md
parent
ed167940
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
README.md
README.md
+2
-2
No files found.
README.md
View file @
5c21d962
...
...
@@ -44,7 +44,7 @@ generator = torch.manual_seed(0)
torch_device
=
"cuda"
if
torch
.
cuda
.
is_available
()
else
"cpu"
# 1. Load models
noise_scheduler
=
GaussianDDPMScheduler
.
from_config
(
"fusing/ddpm-lsun-church"
)
noise_scheduler
=
GaussianDDPMScheduler
.
from_config
(
"fusing/ddpm-lsun-church"
,
tensor_format
=
"pt"
)
unet
=
UNetModel
.
from_pretrained
(
"fusing/ddpm-lsun-church"
).
to
(
torch_device
)
# 2. Sample gaussian noise
...
...
@@ -96,7 +96,7 @@ generator = torch.manual_seed(0)
torch_device
=
"cuda"
if
torch
.
cuda
.
is_available
()
else
"cpu"
# 1. Load models
noise_scheduler
=
DDIMScheduler
.
from_config
(
"fusing/ddpm-celeba-hq"
)
noise_scheduler
=
DDIMScheduler
.
from_config
(
"fusing/ddpm-celeba-hq"
,
tensor_format
=
"pt"
)
unet
=
UNetModel
.
from_pretrained
(
"fusing/ddpm-celeba-hq"
).
to
(
torch_device
)
# 2. Sample gaussian noise
...
...
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