feat(mm): revised list of starter models

- Enriched dependencies to not just be a string - allows reuse of a dependency as a starter model _and_ dependency of another model. For example, all the SDXL models have the fp16 VAE as a dependency, but you can also download it on its own.
- Looked at popular models on the major model sites to select the list. No SD2 models. All hosted on HF.
This commit is contained in:
psychedelicious
2024-03-22 14:11:25 +11:00
parent eb558d72d8
commit 05d6661877
2 changed files with 108 additions and 102 deletions

View File

@ -38,7 +38,7 @@ from invokeai.backend.model_manager.config import (
from invokeai.backend.model_manager.metadata.fetch.huggingface import HuggingFaceMetadataFetch
from invokeai.backend.model_manager.metadata.metadata_base import ModelMetadataWithFiles, UnknownMetadataException
from invokeai.backend.model_manager.search import ModelSearch
from invokeai.backend.model_manager.starter_models import STARTER_MODELS, StarterModel
from invokeai.backend.model_manager.starter_models import STARTER_MODELS, StarterModel, StarterModelWithoutDependencies
from ..dependencies import ApiDependencies
@ -800,9 +800,9 @@ async def get_starter_models() -> list[StarterModel]:
if model.source in installed_model_sources:
model.is_installed = True
# Remove already-installed dependencies
missing_deps: list[str] = []
missing_deps: list[StarterModelWithoutDependencies] = []
for dep in model.dependencies or []:
if dep not in installed_model_sources:
if dep.source not in installed_model_sources:
missing_deps.append(dep)
model.dependencies = missing_deps