Remove additional extra space

pull/59/head
Pedro Cuenca 3 years ago committed by GitHub
parent e2f00b8f10
commit 4aa84acf3a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -122,14 +122,12 @@ public final class PNDMScheduler: Scheduler {
case .scaledLinear:
self.betas = linspace(pow(betaStart, 0.5), pow(betaEnd, 0.5), trainStepCount).map({ $0 * $0 })
}
self.alphas = betas.map({ 1.0 - $0 })
var alphasCumProd = self.alphas
for i in 1..<alphasCumProd.count {
alphasCumProd[i] *= alphasCumProd[i - 1]
}
self.alphasCumProd = alphasCumProd
let stepsOffset = 1 // For stable diffusion
let stepRatio = Float(trainStepCount / stepCount )
let forwardSteps = (0..<stepCount).map {

Loading…
Cancel
Save