fastapi / README.md
benitovvt's picture
Use Docker SDK with model download from HF Hub
2749dce
---
title: Animal Classification API
emoji: 🐾
colorFrom: blue
colorTo: green
sdk: docker
app_port: 7860
pinned: false
---
# Animal Classification API
A FastAPI inference service for classifying images of animals (Cat, Dog, Panda).
## Features
- **FastAPI** REST API with automatic documentation
- **TensorFlow** model for image classification
- **Swagger UI** at `/docs` for interactive testing
- Supports JPG, PNG image uploads
## Usage
1. Open the Space URL
2. Navigate to `/docs` endpoint
3. Try the `POST /upload/image` endpoint
4. Upload an image of a Cat, Dog, or Panda
5. Get instant classification results!
## API Endpoints
- `POST /upload/image` - Upload an image for classification
- `GET /docs` - Interactive API documentation
- `GET /redoc` - Alternative API documentation
## Model
Uses a CNN trained on animal images with 64x64 input resolution.