You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: denoising_diffusion_pytorch/continuous_time_gaussian_diffusion.py
+14-4Lines changed: 14 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -115,6 +115,7 @@ def __init__(
115
115
loss_type='l1',
116
116
noise_schedule='linear',
117
117
num_sample_steps=500,
118
+
clip_sample_denoised=True,
118
119
learned_schedule_net_hidden_dim=1024,
119
120
learned_noise_schedule_frac_gradient=1.# between 0 and 1, determines what percentage of gradients go back, so one can update the learned noise schedule more slowly
120
121
):
@@ -149,6 +150,7 @@ def __init__(
149
150
# sampling
150
151
151
152
self.num_sample_steps=num_sample_steps
153
+
self.clip_sample_denoised=clip_sample_denoised
152
154
153
155
@property
154
156
defdevice(self):
@@ -167,20 +169,28 @@ def p_mean_variance(self, x, time, time_next):
167
169
# reviewer found an error in the equation in the paper (missing sigma)
168
170
# following - https://openreview.net/forum?id=2LdBqxc1Yv¬eId=rIQgH0zKsRt
169
171
170
-
# todo - derive x_start from the posterior mean and do dynamic thresholding
0 commit comments