Stable Diffusion with Core ML on Apple Silicon
41–50 of 184 posts
Re: Stable Diffusion with Core ML on Apple Silicon
#42Earlier quoted context omitted.
Oh gosh that's an intimidating installation process. I'll be much more interested when I can just `brew install` a binary.
> Oh gosh that's an intimidating installation process I'm not seeing any installation instructions on either link - what am I missing?
- create a virtual environment (Python 3.8.15 worked best)
- upgrade pip
- pip install wheel
- pip install -r requirements.txt
- and then, python setup.py install
- Had to update my XCode to use the generated mlpackage files :/
- Expand drawer with instructions and follow them to download model and convert it to Core ML format
- Run their CLI command as mentioned
Re: Stable Diffusion with Core ML on Apple Silicon
#43Re: Stable Diffusion with Core ML on Apple Silicon
#44Atila 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
Last nail in the coffin for DALL·E.
Re: Stable Diffusion with Core ML on Apple Silicon
#45Earlier quoted context omitted.
Oh gosh that's an intimidating installation process. I'll be much more interested when I can just `brew install` a binary.
A bit different take is DiffusionBee, if you're curious to try it out in a GUI form. https://diffusionbee.com
Re: Stable Diffusion with Core ML on Apple Silicon
#46Earlier quoted context omitted.
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?
SD2 wasn’t “neutered”, the piece of it from OpenAI that knew a lot of artist names but wasn’t reproduceable was replaced with a new one from Stability that doesn’t. You can fine-tune anything you want back in.
Re: Stable Diffusion with Core ML on Apple Silicon
#47Great stuff. I like that they give directions for both Swift and Python This gets you text descriptions to images. I have seen models that given a picture, then generate similar pictures. I want this because while I have many pictures of my grandmothers, I only have a couple of pictures of my grandfathers and it would be nice to generate a few more. Core ML is so well done. A year ago I wrote a book on Swift AI and u…
Re: Stable Diffusion with Core ML on Apple Silicon
#48Man, this takes a ton of room to do the CoreML conversions - ran out of space doing the unet conversion even though I started with 25GB free. Going on a delete spree to get it up to 50GB free before trying again.
Re: Stable Diffusion with Core ML on Apple Silicon
#49Earlier quoted context omitted.
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".
For comparison, it's also taking ~3min @ 50 iterations on my 12c Threadripper using OpenVino. It sounds like the improvements bring the M1 performance roughly in line with a GTX 1080.
Re: Stable Diffusion with Core ML on Apple Silicon
#50Earlier quoted context omitted.
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".
For comparison, it's also taking ~3min @ 50 iterations on my 12c Threadripper using OpenVino. It sounds like the improvements bring the M1 performance roughly in line with a GTX 1080.
So sounds plausible that the m1 can reach the same level in some use cases with the right optimizations.