danielle2035's picture
Initial clean Space deployment
01ba07a
|
Raw
History Blame Contribute Delete
1.03 kB

Minimal Hugging Face Space for Intel Image Classifier

This folder contains a minimal Hugging Face Space app using a custom index.html frontend and a Python backend.

Files

  • app.py — FastAPI backend for prediction and frontend delivery
  • index.html — frontend UI for uploading images and selecting the model
  • requirements.txt — dependencies
  • models/ — place your trained models here

Model files required

Place your trained models in hf_space/models/:

  • pytorch_model.pth
  • model_best.keras

Deploying on Hugging Face Spaces

  1. Create a new Space on Hugging Face
  2. Select Python SDK
  3. Push the contents of this hf_space/ directory to the new Space repository

The Space will run app.py automatically and serve index.html as the frontend.

Docker support

A Dockerfile is included so you can also build and run the app locally in a container.

Local testing

From hf_space/:

pip install -r requirements.txt
python app.py

Then open:

  • http://localhost:7860