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
79c0e24a
Unverified
Commit
79c0e24a
authored
May 04, 2023
by
Cesar Aybar
Committed by
GitHub
May 04, 2023
Browse files
Update write_own_pipeline.mdx (#3323)
parent
fa9e35fc
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
docs/source/en/using-diffusers/write_own_pipeline.mdx
docs/source/en/using-diffusers/write_own_pipeline.mdx
+3
-3
No files found.
docs/source/en/using-diffusers/write_own_pipeline.mdx
View file @
79c0e24a
...
...
@@ -82,8 +82,8 @@ To recreate the pipeline with the model and scheduler separately, let's write ou
>>> for t in scheduler.timesteps:
... with torch.no_grad():
... noisy_residual = model(input, t).sample
>>>
previous_noisy_sample = scheduler.step(noisy_residual, t, input).prev_sample
>>>
input = previous_noisy_sample
...
previous_noisy_sample = scheduler.step(noisy_residual, t, input).prev_sample
...
input = previous_noisy_sample
```
This is the entire denoising process, and you can use this same pattern to write any diffusion system.
...
...
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