Instructions to use gatilin/lance_wan22_vae with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Wan2.2
How to use gatilin/lance_wan22_vae with Wan2.2:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Download component.py from gatilin/lance_wan22_vae: direct link, hf CLI and curl.
- Browser
- Download file 305 Bytes
-
https://huggingface.co/gatilin/lance_wan22_vae/resolve/main/component.py
- Command line
-
hf download hf://gatilin/lance_wan22_vae/component.py
-
curl -L -o component.py https://huggingface.co/gatilin/lance_wan22_vae/resolve/main/component.py
305 Bytes
| """Strict native loader for the Wan2.2 VAE shipped by Lance.""" | |
| from pathlib import Path | |
| import torch | |
| from native.vae2_2 import Wan2_2_VAE | |
| def load_model(root, *, device='cpu', dtype=torch.float32): | |
| root = Path(root) | |
| return Wan2_2_VAE(vae_pth=str(root / 'model.pth'), device=device, dtype=dtype) | |