Live data from Hacker News

Stable Diffusion with Core ML on Apple Silicon

machinelearning.apple.com

11–20 of 184 posts

Re: Stable Diffusion with Core ML on Apple Silicon

#12
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

SD2 is the one that was neutered, right?

Maybe a dumb question but can the old model still be run?

Re: Stable Diffusion with Core ML on Apple Silicon

#13
post #12
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

SD2 is the one that was neutered, right? Maybe a dumb question but can the old model still be run?

Also, can you not "upgrade" but still run new models?

Re: Stable Diffusion with Core ML on Apple Silicon

#14
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

With the full 50 iterations it appears to be about 30s on M1.

They have some benchmarks on the github repo: https://github.com/apple/ml-stable-diffusion

For reference, previously I was getting about <3 minutes for 50 iterations on my Macbook Air M1. I haven't yet tried Apple's implementation but it looks like a huge improvement. It might take it from "possible" to "usable".

Re: Stable Diffusion with Core ML on Apple Silicon

#15
post #12
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

SD2 is the one that was neutered, right? Maybe a dumb question but can the old model still be run?

It's less versatile out of the box. Give it a couple months for the community to catch up. Everyone is still figuring out what goes where, and SD 1.x was "everything goes in one spot." It was cool and powerful, but limited.

Re: Stable Diffusion with Core ML on Apple Silicon

#16
post #7
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

i'm very ignorant here so forgive me but if it can generate images that fast can it be used to generate a video?

Yeah, sure. The issue is with temporal consistency. Meta and Google have some successes in that area.

https://mezha.media/en/2022/10/06/google-is-working-on-image...

Give it some time and SD will be able to do the same.

Re: Stable Diffusion with Core ML on Apple Silicon

#17
post #7
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

i'm very ignorant here so forgive me but if it can generate images that fast can it be used to generate a video?

There are different requirements for generating video -- at a minimum, continuity is tough. There are models for producing video, but (as far as I've seen) they're still a bit wobbly.

Re: Stable Diffusion with Core ML on Apple Silicon

#18
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

Note that this is extrapolation for the distilled model which isn't released quite yet. (but it will be very exciting when it does!)

Re: Stable Diffusion with Core ML on Apple Silicon

#19
post #12
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

SD2 is the one that was neutered, right? Maybe a dumb question but can the old model still be run?

You can still do nice things with SD2, it just requires a different approach. https://news.ycombinator.com/item?id=33780543

Re: Stable Diffusion with Core ML on Apple Silicon

#20
post #14
post #2

Atila from Apple on the expected performance: > For distilled StableDiffusion 2 which requires 1 to 4 iterations instead of 50, the same M2 device should generate an image in https://twitter.com/atiorh/status/1598399408160342039

With the full 50 iterations it appears to be about 30s on M1. They have some benchmarks on the github repo: https://github.com/apple/ml-stable-diffusion For reference, previously I was getting about <3 minutes for 50 iterations on my Macbook Air M1. I haven't yet tried Apple's implementation but it looks like a huge improvement. It might take it from "possible" to "usable".

Yeah, it is just PyTorch MPS backend is not fully baked and have some slowness. You should be able to get close to that number with maple-diffusion (probably 10% slower) or my app: https://drawthings.ai/ (probably around 20% slower, but it supports samplers that takes less steps (50 -> 30)).
Post reply on HN