Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENHANCEMENT] More descriptive get_loaded_models endpoint #635

Open
vicilliar opened this issue Nov 3, 2023 · 0 comments
Open

[ENHANCEMENT] More descriptive get_loaded_models endpoint #635

vicilliar opened this issue Nov 3, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@vicilliar
Copy link
Contributor

Is your feature request related to a problem? Please describe.
Currently, get_loaded_models returns model_device and model_name, which is based on the alias given as model in index defaults by a user. This is good when the model is in the registry, as the model alias usually matches the model_properties["name"], however this isn't always the case. Especially when users use custom models, it may be worth it to return more information in get_loaded_models.

For example, if an index is defined with:

settings={
    "index_defaults": {
        "model": "my_custom_model",
        "model_properties": {
            "name": "ViT-B-32-quickgelu",
            "dimensions": 512,
            "url": "https://github.com/mlfoundations/open_clip/releases/download/v0.2-weights/vit_b_32-quickgelu-laion400m_avg-8a00ab3c.pt",
            "type": "open_clip"
        }
    }
}

Currently get_loaded_models will only give you:

[
    {
        "model_name": "my_custom_model",
        "model_device": "cpu"
    }
]

Describe the solution you'd like
We should return other valuable info about the model, including:

  1. memory size
  2. model_properties["name"], as it's usually more useful than just model
  3. URL downloaded from (if it's a custom model)
@vicilliar vicilliar added the enhancement New feature or request label Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant