akagtag's picture
Implement ZeroGPU Space runtime
eff3d67

A newer version of the Gradio SDK is available: 6.14.0

Upgrade

Module Status - 2026-04-28 02:11 +05:30

Module Status Notes
M1 LipSync wip modules/m1_lipsync.py now follows CPU init plus to_gpu/to_cpu; imports lipfd.model.LipFDNet; loads AkshatAgarwal/LipFD-checkpoint/ckpt.pth. Local LipFDNet is a minimal compatible wrapper, not the full upstream LipFD source tree.
M2 Fingerprint wip modules/m2_fingerprint.py now loads yermandy/deepfake-detection and CLIP on CPU, moves to CUDA inside ZeroGPU request, and returns fake score plus generator attribution.
M3 SSTGNN wip modules/m3_sstgnn.py now imports real SSTGNN instead of fallback; modules/sstgnn_model.py added; utils/graph.py builds patch graph with x, x_temporal, and edge_index. Requires hosted AkshatAgarwal/SSTGNN-deepfake/sstgnn_best.pt.
M5 Fusion done modules/m5_fusion.py unchanged; generated required weights/fusion_mlp.pt; .gitignore now allows committing this exact .pt file.
M5 Explain done modules/m5_explain.py now calls NVIDIA NIM meta/llama-3.1-8b-instruct through OpenAI-compatible client and falls back to deterministic explanation on API failure.
Infra/Space done README.md now declares HuggingFace Space metadata including hardware: zero-gpu; app.py imports spaces, decorates analyze() with @spaces.GPU(duration=120), loads modules at startup on CPU, and transfers GPU modules for each request.
Tests done Added tests/test_zero_gpu_contract.py; full local test suite passed with 59 tests and 9 warnings.
Context Store blocked Obsidian MCP is not connected in the current Codex session; list_mcp_resources and list_mcp_resource_templates returned empty. Local fallback notes were written under Obsidian/GenAI-DeepDetect/.