Spaces:
Paused
Paused
File size: 3,165 Bytes
068b511 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 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 |
# CogVideoX Keyframe Interpolation - Quick Setup
This directory contains the **bare minimum files** needed to run the CogVideoX Keyframe Interpolation Gradio app.
## 📁 Contents
```
CogVideoXInterp/
├── README.md # HuggingFace Spaces README
├── app.py # Main Gradio application
├── requirements.txt # Python dependencies
├── cogvideox_interpolation/ # Core pipeline module
│ ├── datasets.py # Dataset loading (not needed for inference)
│ └── pipeline.py # Custom interpolation pipeline
└── SETUP.md # This file
```
**Total size:** ~64KB (model downloads separately)
---
## 🚀 Quick Start
### Local Setup
1. **Install dependencies:**
```bash
pip install -r requirements.txt
```
2. **Run the app:**
```bash
python app.py
```
3. **Open browser:**
Navigate to `http://localhost:7860`
### GPU Requirements
- **Minimum:** 16GB VRAM (RTX 4060 Ti 16GB, RTX 4080)
- **Recommended:** 24GB VRAM (RTX 3090, RTX 4090)
---
## 🤗 Deploy to HuggingFace Spaces
### Method 1: Web Upload
1. Go to https://huggingface.co/spaces
2. Click "Create new Space"
3. Choose **Gradio** as SDK
4. Upload all files from this directory
5. Select GPU hardware (T4 minimum, A10G recommended)
6. Space will auto-deploy!
### Method 2: Git Push
```bash
# Create a Space on HuggingFace first, then:
git clone https://huggingface.co/spaces/YOUR_USERNAME/YOUR_SPACE_NAME
cd YOUR_SPACE_NAME
# Copy files
cp -r /path/to/CogVideoXInterp/* .
# Push
git add .
git commit -m "Initial commit"
git push
```
### HuggingFace Spaces Hardware Options
| Hardware | VRAM | Speed | Cost/hr |
|----------|------|-------|---------|
| CPU | 0GB | ❌ Won't work | Free |
| T4 | 16GB | ⚠️ Slow (5-8 min) | ~$0.60 |
| A10G | 24GB | ✅ Good (2-4 min) | ~$3.15 |
| A100 | 40GB | ✅ Fast (1-2 min) | ~$7.00 |
**Note:** Model will auto-download on first run (~20GB)
---
## 📝 Usage
1. **Load Model** - Enter model path or use default `feizhengcong/CogvideoX-Interpolation`
2. **Upload Images** - Provide start and end frame
3. **Write Prompt** - Describe the motion/transition
4. **Generate** - Wait 2-5 minutes for video
### Example Prompts
✅ "A person walks forward slowly, their body moving naturally with each step"
✅ "The camera smoothly pans from left to right, revealing the scene"
✅ "A dancer gracefully transitions from one pose to another"
---
## 🔧 Troubleshooting
### Out of Memory
Reduce parameters in the app:
- Frames: 49 → 25
- Steps: 50 → 30
### Model Download Fails
Check internet connection. Model is ~20GB and downloads to:
- Linux/Mac: `~/.cache/huggingface/`
- Windows: `C:\Users\USERNAME\.cache\huggingface\`
### Import Errors
Make sure all files from this directory are in the same location, especially the `cogvideox_interpolation/` folder.
---
## 📚 More Information
For detailed documentation, see the parent repository at:
https://github.com/feizc/CogvideX-Interpolation
**Model:** https://huggingface.co/feizhengcong/CogvideoX-Interpolation
**License:** Apache 2.0 |