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
chenpangpang
ComfyUI
Commits
821f9387
Commit
821f9387
authored
Jul 16, 2024
by
comfyanonymous
Browse files
Allow model sampling to set number of timesteps.
parent
e1630391
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
comfy/model_sampling.py
comfy/model_sampling.py
+2
-1
No files found.
comfy/model_sampling.py
View file @
821f9387
...
...
@@ -59,8 +59,9 @@ class ModelSamplingDiscrete(torch.nn.Module):
beta_schedule
=
sampling_settings
.
get
(
"beta_schedule"
,
"linear"
)
linear_start
=
sampling_settings
.
get
(
"linear_start"
,
0.00085
)
linear_end
=
sampling_settings
.
get
(
"linear_end"
,
0.012
)
timesteps
=
sampling_settings
.
get
(
"timesteps"
,
1000
)
self
.
_register_schedule
(
given_betas
=
None
,
beta_schedule
=
beta_schedule
,
timesteps
=
1000
,
linear_start
=
linear_start
,
linear_end
=
linear_end
,
cosine_s
=
8e-3
)
self
.
_register_schedule
(
given_betas
=
None
,
beta_schedule
=
beta_schedule
,
timesteps
=
timesteps
,
linear_start
=
linear_start
,
linear_end
=
linear_end
,
cosine_s
=
8e-3
)
self
.
sigma_data
=
1.0
def
_register_schedule
(
self
,
given_betas
=
None
,
beta_schedule
=
"linear"
,
timesteps
=
1000
,
...
...
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