Skip to content

[bug]: CLIP Model Download Fails to Create Required Subdirectory Structure #8376

@sapochat

Description

@sapochat

Is there an existing issue for this problem?

  • I have searched the existing issues

Install method

Invoke's Launcher

Operating system

Windows

GPU vendor

Nvidia (CUDA)

GPU model

RTX 5090

GPU VRAM

32GB

Version number

v6.3.0rc1

Browser

No response

System Information

No response

What happened

InvokeAI version 6.3.0rc1 on Windows fails to create the necessary subdirectory structure for CLIP models, leading to HFValidationError.

When downloading the CLIP-GmP-ViT-L-14 model as a dependency for the FLUX text encoder, the model files are saved directly into the root directory of the model instead of the required text_encoder and tokenizer subdirectories.

This results in the following error during loading:
HFValidationError: Repo id must use alphanumeric chars or '-', '_', '.', '--' and '..' are forbidden, '-' and '.' cannot start or end the name, max length is 96: 'D:\Invoke\models\any\clip_embed\CLIP-GmP-ViT-L-14\text_encoder'.

The current download structure:
CLIP-GmP-ViT-L-14/ ├── config.json ├── merges.txt ├── model.safetensors ├── preprocessor_config.json ├── special_tokens_map.json ├── tokenizer_config.json ├── tokenizer.json └── vocab.json

What you expected to happen

Expected Structure:
CLIP-GmP-ViT-L-14/ ├── text_encoder/ │ ├── config.json │ └── model.safetensors ├── tokenizer/ │ ├── merges.txt │ ├── special_tokens_map.json │ ├── tokenizer_config.json │ ├── tokenizer.json │ └── vocab.json ├── config.json └── preprocessor_config.json

How to reproduce the problem

Steps to Reproduce:

  1. Install InvokeAI and attempt to download the FLUX model requiring CLIP-GmP-ViT-L-14.
  2. InvokeAI downloads the CLIP model but fails to create necessary subdirectories.
  3. An error occurs when loading the model due to incorrect path structure.

Additional context

Workaround:
Manually create the text_encoder and tokenizer directories and move the appropriate files into these subdirectories.

Discord username

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions