Download utils/load_models.py from philschmid/sagemaker-launcher: direct link, hf CLI and curl.
- Browser
- Download file 184 Bytes
-
https://huggingface.co/spaces/philschmid/sagemaker-launcher/resolve/main/utils/load_models.py
- Command line
-
hf download hf://spaces/philschmid/sagemaker-launcher/utils/load_models.py
-
curl -L -o load_models.py https://huggingface.co/spaces/philschmid/sagemaker-launcher/resolve/main/utils/load_models.py
184 Bytes
| import requests | |
| import streamlit as st | |
| def load_models(): | |
| res = requests.get("https://huggingface.co/api/models").json() | |
| return [model["modelId"] for model in res] | |