divamgupta / stable-diffusion-tensorflow

Stable Diffusion in TensorFlow / Keras
Other
1.57k stars 227 forks source link

Random initialization and diffuse #7

Closed tcapelle closed 1 year ago

tcapelle commented 1 year ago

Hey, thanks for putting this together =).

The code is actually substantially faster than the PyTorch counterpart on M1Pro. Even from the CoreML version. I am getting the same results every time; it appears that the random noise is kind of "deterministic" in the text2image function. Here I call the diffusion twice: https://github.com/tcapelle/stable-diffusion-tensorflow/blob/master/02_inference.ipynb Can you explain a little bit why all these hardcoded alphas are necessary?

tcapelle commented 1 year ago

It appears to be an issue on Mac OS only...

soumik12345 commented 1 year ago

Here's the issue and the workaround suggested: https://developer.apple.com/forums/thread/697057