Spaces:
Runtime error
Runtime error
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,48 +1,59 @@
|
|
| 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 |
*Replace `<your-username>-<space-name>` with your actual Hugging Face Space URL.*
|
|
|
|
| 1 |
+
---
|
| 2 |
+
title: Cat Breed Classifier
|
| 3 |
+
emoji: 🐱
|
| 4 |
+
colorFrom: indigo
|
| 5 |
+
colorTo: pink
|
| 6 |
+
sdk: gradio
|
| 7 |
+
sdk_version: "4.0.0"
|
| 8 |
+
app_file: app.py
|
| 9 |
+
pinned: false
|
| 10 |
+
---
|
| 11 |
+
|
| 12 |
+
# Cat Breed Classifier 🐱
|
| 13 |
+
|
| 14 |
+
This Hugging Face Space uses a deep learning model to classify cat breeds from images. Upload a photo of a cat, and the app will predict its breed!
|
| 15 |
+
|
| 16 |
+
## How It Works
|
| 17 |
+
- The app is built with [Gradio](https://gradio.app/) and [TensorFlow](https://www.tensorflow.org/).
|
| 18 |
+
- The model was trained to recognize 12 popular cat breeds.
|
| 19 |
+
- Just upload an image, and you'll get the predicted breed and confidence score.
|
| 20 |
+
|
| 21 |
+
## Supported Cat Breeds
|
| 22 |
+
- Abyssinian
|
| 23 |
+
- Bengal
|
| 24 |
+
- Birman
|
| 25 |
+
- Bombay
|
| 26 |
+
- British Shorthair
|
| 27 |
+
- Egyptian Mau
|
| 28 |
+
- Maine Coon
|
| 29 |
+
- Persian
|
| 30 |
+
- Ragdoll
|
| 31 |
+
- Russian Blue
|
| 32 |
+
- Siamese
|
| 33 |
+
- Sphynx
|
| 34 |
+
|
| 35 |
+
## Usage
|
| 36 |
+
1. Click the **Upload** button and select a cat image (JPG/PNG).
|
| 37 |
+
2. Wait a moment for the model to process the image.
|
| 38 |
+
3. View the predicted breed and confidence score.
|
| 39 |
+
|
| 40 |
+
## API
|
| 41 |
+
You can also use this Space as an API by sending a POST request to the `/run/predict` endpoint with an image file.
|
| 42 |
+
|
| 43 |
+
**Example using `requests` in Python:**
|
| 44 |
+
```python
|
| 45 |
+
import requests
|
| 46 |
+
|
| 47 |
+
url = "https://<your-username>-<space-name>.hf.space/run/predict"
|
| 48 |
+
files = {"data": ("cat.jpg", open("cat.jpg", "rb"), "image/jpeg")}
|
| 49 |
+
response = requests.post(url, files=files)
|
| 50 |
+
print(response.json())
|
| 51 |
+
```
|
| 52 |
+
|
| 53 |
+
## Credits
|
| 54 |
+
- Built with Gradio and TensorFlow
|
| 55 |
+
- Model trained by <your-name-or-team>
|
| 56 |
+
|
| 57 |
+
---
|
| 58 |
+
|
| 59 |
*Replace `<your-username>-<space-name>` with your actual Hugging Face Space URL.*
|