--- title: Rice Disease Detection emoji: 🌾 colorFrom: green colorTo: yellow sdk: gradio python_version: "3.12" app_file: app.py preload_from_hub: - cvmil/dinov2-base_rice-leaf-disease-augmented_fft - openai/clip-vit-large-patch14 --- # Rice Disease Detection Upload a close-up rice leaf photo to identify disease and view treatment guidance. This demo uses shared ZeroGPU hardware with daily usage limits and queuing. Named Gradio endpoints: `/predict` (one uploaded file, JSON result) and `/diseases` (no inputs, JSON catalog). Non-rice and invalid uploads return a JSON `detail` field. This is a Gradio API, not the FastAPI `/predict` route. Optional scan persistence: add R2_ENDPOINT_URL, R2_ACCESS_KEY_ID, R2_SECRET_ACCESS_KEY, R2_BUCKET_NAME, SUPABASE_URL, and SUPABASE_SECRET_KEY in Space Settings → Secrets. Never upload environment files. The Raspberry Pi FastAPI `/device/predict` endpoint is not exposed by this Space.