LykosAI / StabilityMatrix

Multi-Platform Package Manager for Stable Diffusion
https://lykos.ai
GNU Affero General Public License v3.0
4.34k stars 278 forks source link

Question: Multiple checkpoint/LORA directories? #846

Open CHollman823 opened 4 weeks ago

CHollman823 commented 4 weeks ago

I know you can change the directory with the command line option for A111, but is there a way to use like 3 or 4 different directories at the same time with their contents just being merged in the UI? Also, is there a way to change where they are downloaded to when using the built-in model browser?

richardm1 commented 3 weeks ago

Is the goal to split the contents of \Data\Models across multiple drives? If so I might have a workaround...

CHollman823 commented 3 weeks ago

Is the goal to split the contents of \Data\Models across multiple drives? If so I might have a workaround...

Yeah exactly... I have terabytes of the stuff and it's clogging up my SSD, I'd like to put lesser-used ones on a slower but much larger drive.

richardm1 commented 3 weeks ago

Yeah exactly... I have terabytes of the stuff and it's clogging up my SSD, I'd like to put lesser-used ones on a slower but much larger drive.

This evening I've experimented with moving various folders under StabilityMatrix\Data to different drives. Then I created NTFS junctions to make the folders appear at their original locations. It didn't work with packages\ComfyUI -- Stability Matrix removes the damn junction when I launch the package.

Next I tried moving the entire Packages folder and all contents out to a different drive. Forge seemed to handle it just fine. Then I tried SD.next which during startup figures out that it's running from a different drive and throws an error. Scratch that idea.

The only thing I've moved successfully (so far) that seems to work 100% is the LoRA folder under models. This doesn't seem to interfere or interact with the junctions that Stability Matrix matrix creates to point each package to the common models folder. The packages don't seem to mind the double-hop through junctions.

Anyway, with Stability Matrix shut down I moved my Lora folder out to a better location. Then I used this PowerShell one liner to create a junction at the original location:

New-Item -Type Junction -Path S:\StabilityMatrix\Data\Models\Lora -Target D:\StabilityMatrix\Data\Models\Lora -Verbose

I thought I had a better solution for you/us. But moving the lora folder is a good start I reckon.

CHollman823 commented 3 weeks ago

Hey thanks that's a lot better than nothing! LoRA's are pretty big, especially SDXL ones (I have several that are nearly 2gb each) so it definitely helps.

richardm1 commented 2 weeks ago

Data\Assets appears safe to relocate as well. Still testing...