Skip to content

Commit

Permalink
refactor: syntax and add 0.0 on new line
Browse files Browse the repository at this point in the history
  • Loading branch information
v0xie committed Jul 19, 2024
1 parent a5f66b5 commit 7e1bd3e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/sd_schedulers.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@ def beta_scheduler(n, sigma_min, sigma_max, inner_model, device):
beta = 0.6
timesteps = 1 - np.linspace(0, 1, n)
timesteps = [stats.beta.ppf(x, alpha, beta) for x in timesteps]
sigmas = [sigma_min + ((x)*(sigma_max-sigma_min)) for x in timesteps] + [0.0]
sigmas = torch.FloatTensor(sigmas).to(device)
return sigmas
sigmas = [sigma_min + (x * (sigma_max-sigma_min)) for x in timesteps]
sigmas += [0.0]
return torch.FloatTensor(sigmas).to(device)


schedulers = [
Expand Down

0 comments on commit 7e1bd3e

Please sign in to comment.