cifar10-classifier / README.md
mramjad's picture
Update README.md
70f0ac0 verified
---
library_name: onnx
pipeline_tag: image-classification
---
# CIFAR-10 Classifier
This is a CIFAR-10 image classification model trained using PyTorch and exported to ONNX format.
## Usage
You can use this model via the Hugging Face Inference API.
### Python Example
```python
import requests
API_URL = "https://api-inference.huggingface.co/models/mramjad/cifar10-classifier"
headers = {"Authorization": "Bearer <your-api-token>"}
def query(image_path):
with open(image_path, "rb") as file:
response = requests.post(API_URL, headers=headers, files={"file": file})
return response.json()
result = query("path/to/your/image.jpg")
print(result)