Skip to content

Commit

Permalink
Fix the issue + Remove unused arg (#2113)
Browse files Browse the repository at this point in the history
  • Loading branch information
ID6109 authored Oct 23, 2023
1 parent 11d30cc commit 832e2d9
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions keras_cv/models/stable_diffusion/noise_scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ class NoiseScheduler:
beta_schedule: the beta schedule, a mapping from a beta range to a
sequence of betas for stepping the model. Choose from `linear` or
`quadratic`.
betas: a complete set of betas, in lieu of using one of the existing
schedules.
variance_type: options to clip the variance used when adding noise to
the de-noised sample. Choose from `fixed_small`, `fixed_small_log`,
`fixed_large`, `fixed_large_log`, `learned` or `learned_range`.
Expand Down Expand Up @@ -65,7 +63,7 @@ def __init__(
raise ValueError(f"Invalid beta schedule: {beta_schedule}.")

self.alphas = 1.0 - self.betas
self.alphas_cumprod = ops.math.cumprod(self.alphas)
self.alphas_cumprod = ops.cumprod(self.alphas)

self.variance_type = variance_type
self.clip_sample = clip_sample
Expand Down

0 comments on commit 832e2d9

Please sign in to comment.