A MobileNetV3-based gate classification service containerized with Docker and GPU support.
gate_mobilenetv3.pth)Option 1: Using Docker Compose (Recommended)
docker-compose up --build
Option 2: Using Build Scripts
# Linux/Mac
chmod +x deploy.sh
./deploy.sh
# Windows
deploy.bat
Option 3: Manual Docker Commands
# Build
docker build -t gate-classifier .
# Run
docker run -d --name gate-classifier-app --gpus all -p 8000:8000 gate-classifier
GET /healthPOST /classify (upload image)GET /http://localhost:8000/docsimport requests
# Test the API
url = "http://localhost:8000/classify"
with open("gate_image.jpg", "rb") as f:
files = {"file": f}
response = requests.post(url, files=files)
print(response.json())
CUDA_VISIBLE_DEVICES: GPU device selection (default: 0)gate_mobilenetv3.pth (required)gate_mobilenetv3_best.pth (optional, preferred if available)# View logs
docker logs -f gate-classifier-app
# Shell access
docker exec -it gate-classifier-app /bin/bash
# Stop container
docker stop gate-classifier-app
# Remove container
docker rm gate-classifier-app
Content type
Image
Digest
sha256:dca0e60d4…
Size
510.3 MB
Last updated
11 months ago
docker pull valiente/gate-classifier-onnx-intel