Text-to-Video
Diffusers
Safetensors
English
CogVideoXPipeline
ternary-quant
quantization
ternary
video-generation
dit
cogvideox
Instructions to use AsadIsmail/CogVideoX-2b-ternary with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use AsadIsmail/CogVideoX-2b-ternary with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("AsadIsmail/CogVideoX-2b-ternary", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Correct CogVideoX base reference
Browse files
README.md
CHANGED
|
@@ -134,7 +134,7 @@ The quantization pipeline is at [github.com/Asad-Ismail/ternary-models/tree/main
|
|
| 134 |
```python
|
| 135 |
# 1. Load pipeline
|
| 136 |
from diffusers import DiffusionPipeline
|
| 137 |
-
pipe = DiffusionPipeline.from_pretrained("
|
| 138 |
|
| 139 |
# 2. Extract DiT transformer
|
| 140 |
transformer = pipe.transformer
|
|
|
|
| 134 |
```python
|
| 135 |
# 1. Load pipeline
|
| 136 |
from diffusers import DiffusionPipeline
|
| 137 |
+
pipe = DiffusionPipeline.from_pretrained("zai-org/CogVideoX-2b", torch_dtype=torch.float16)
|
| 138 |
|
| 139 |
# 2. Extract DiT transformer
|
| 140 |
transformer = pipe.transformer
|