MCPcopy Create free account
hub / github.com/Royalvice/DocDiff / sigmoid_beta_schedule

Method sigmoid_beta_schedule

schedule/schedule.py:33–39  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

31 return torch.linspace(beta_start ** 0.5, beta_end ** 0.5, timesteps) ** 2
32
33 def sigmoid_beta_schedule(self):
34 timesteps = self.timesteps
35 scale = 1000 / timesteps
36 beta_start = 1e-6 * scale
37 beta_end = 0.02 * scale
38 betas = torch.linspace(-6, 6, timesteps)
39 return torch.sigmoid(betas) * (beta_end - beta_start) + beta_start
40
41 def get_betas(self):
42 if self.schedule == "linear":

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected