cli ¶
Functions:
-
clear–Delete downloaded ONNX models or built TensorRT & MIGraphxX artifacts.
-
download–Download ONNX models.
-
meta_main– -
show–List downloaded ONNX models or built TensorRT & MIGraphxX artifacts.
Attributes:
-
MAX_CONCURRENCY– -
app– -
artifact_app– -
console– -
onnx_app–
app module-attribute ¶
app = App(
name="vsscale",
version=__version__,
help="CLI utility for managing machine learning models and TensorRT/MIGraphX artifacts for VapourSynth.",
help_on_error=True,
console=console,
config=[
Env("VSSCALE_"),
Toml(TOML_CONFIG[0], root_keys=TOML_KEYS[0], allow_unknown=True),
Toml(TOML_CONFIG[1], root_keys=TOML_KEYS[1], allow_unknown=True),
],
)
artifact_app module-attribute ¶
artifact_app = App(
name="artifact", help="Manage built TensorRT and MIGraphxX artifacts."
)
clear ¶
clear(
global_: Annotated[
bool,
Parameter(
negative=(),
show_default=False,
env_var=[VSSCALE_CLEAR_GLOBAL, VSSCALE_GLOBAL],
),
] = False,
) -> None
Delete downloaded ONNX models or built TensorRT & MIGraphxX artifacts.
If no model specs are provided, the entire directory is cleared.
Parameters:
-
(global_¶Annotated[bool, Parameter(negative=(), show_default=False, env_var=[VSSCALE_CLEAR_GLOBAL, VSSCALE_GLOBAL])], default:False) –Whether to clear files in the global folder.
Source code in vsscale/mlrt/cli.py
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 | |
download async ¶
download(
*provider: Annotated[str, Parameter(name=--provider)],
latest: Annotated[
bool,
Parameter(
negative=(),
show_default=False,
env_var=[VSSCALE_ONNX_DOWNLOAD_LATEST, VSSCALE_LATEST],
),
] = False,
global_: Annotated[
bool,
Parameter(
negative=(),
show_default=False,
env_var=[VSSCALE_ONNX_DOWNLOAD_GLOBAL, VSSCALE_GLOBAL],
),
] = False,
) -> None
Download ONNX models.
Supports multiple invocation styles
- Interactive: vsscale onnx download
- Pick tag for model: vsscale onnx download ArtCNN
- Pinned version: vsscale onnx download ArtCNN==v1.6.2
- Latest release: vsscale onnx download ArtCNN --latest
If a vsjet.toml or a pyproject.toml file is detected with a valid configuration, the interactive mode may be partially or fully skipped.
Parameters:
-
(provider¶Annotated[str, Parameter(name=--provider)], default:()) –The ONNX model(s) to download. Possible choices: "ArtCNN", "DPIR", "Waifu2X". Use '==' syntax to pin a version (e.g. ArtCNN==v1.6.2).
-
(latest¶Annotated[bool, Parameter(negative=(), show_default=False, env_var=[VSSCALE_ONNX_DOWNLOAD_LATEST, VSSCALE_LATEST])], default:False) –Whether to automatically download all models from the latest release.
-
(global_¶Annotated[bool, Parameter(negative=(), show_default=False, env_var=[VSSCALE_ONNX_DOWNLOAD_GLOBAL, VSSCALE_GLOBAL])], default:False) –Whether to download models to the global folder.
Source code in vsscale/mlrt/cli.py
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |
meta_main ¶
meta_main(
*tokens: Annotated[str, Parameter(show=False)],
no_config: Annotated[
bool,
Parameter(
negative=(),
show_default=False,
help="Ignore TOML configuration files and environment variables.",
),
] = False,
) -> None
Source code in vsscale/mlrt/cli.py
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 | |
show ¶
show(
global_: Annotated[
bool,
Parameter(
negative=(),
show_default=False,
env_var=[VSSCALE_SHOW_GLOBAL, VSSCALE_GLOBAL],
),
] = False,
) -> None
List downloaded ONNX models or built TensorRT & MIGraphxX artifacts.
Parameters:
-
(global_¶Annotated[bool, Parameter(negative=(), show_default=False, env_var=[VSSCALE_SHOW_GLOBAL, VSSCALE_GLOBAL])], default:False) –Whether to show models in the global folder.
Source code in vsscale/mlrt/cli.py
148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 | |