mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-04-23 03:00:31 -04:00
enhance model autodetection during import
- Imported V2 legacy models will now autoconvert into diffusers at load time regardless of setting of --ckpt_convert. - model manager `heuristic_import()` function now looks for side-by-side yaml and vae files for custom configuration and VAE respectively. Example of this: illuminati-v1.1.safetensors illuminati-v1.1.vae.safetensors illuminati-v1.1.yaml When the user tries to import `illuminati-v1.1.safetensors`, the yaml file will be used for its configuration, and the VAE will be used for its VAE. Conversion to diffusers will happen if needed, and the yaml file will be used to determine which V2 format (if any) to apply.
This commit is contained in:
@@ -211,6 +211,26 @@ description for the model, whether to make this the default model that
|
||||
is loaded at InvokeAI startup time, and whether to replace its
|
||||
VAE. Generally the answer to the latter question is "no".
|
||||
|
||||
### Specifying a configuration file for legacy checkpoints
|
||||
|
||||
Some checkpoint files come with instructions to use a specific .yaml
|
||||
configuration file. For InvokeAI load this file correctly, please put
|
||||
the config file in the same directory as the corresponding `.ckpt` or
|
||||
`.safetensors` file and make sure the file has the same basename as
|
||||
the weights file. Here is an example:
|
||||
|
||||
```bash
|
||||
wonderful-model-v2.ckpt
|
||||
wonderful-model-v2.yaml
|
||||
```
|
||||
|
||||
Similarly, to use a custom VAE, name the VAE like this:
|
||||
|
||||
```bash
|
||||
wonderful-model-v2.vae.pt
|
||||
```
|
||||
|
||||
|
||||
### Converting legacy models into `diffusers`
|
||||
|
||||
The CLI `!convert_model` will convert a `.safetensors` or `.ckpt`
|
||||
|
||||
Reference in New Issue
Block a user