This is the Node.js / Express.js conversion of the original Flask-based Uniform Detection Application.
It delivers the same AI-powered functionality with a modern JavaScript backend, ensuring better scalability and maintainability.
🔥 Try it out now:
👉 OPEN UNIFORM DETECTION MODEL APP
- 🎯 Real-time Uniform Detection using YOLOv8 / TensorFlow.js
- 📸 Image Upload & Camera Capture capabilities
- 💻 Responsive and Interactive UI built for web and mobile
- ⚙️ Instant Processing & Visualization of detection results
- 📊 Confidence Score and detection highlights displayed in real time
Make sure you have the following installed before running the app:
- 🟢 Node.js (v14 or higher)
- 🟣 npm (v6 or higher)
- Clone or download this repository
git clone https://github.com/yourusername/uniform-detection-node.git cd uniform-detection-node - Install dependencies:
npm install
To start the development server:
npm run devTo start the production server:
npm startThen open your browser and visit 👉 http://localhost:3000
.
├── server.js # Main Express.js server file
├── package.json # Project dependencies and scripts
├── templates/ # HTML templates
│ └── index.html # Main application page
├── static/ # Static assets
│ ├── css/
│ │ └── style.css # Application styles
│ └── js/
│ └── script.js # Frontend JavaScript
├── model/ # ML model files
│ └── uniform_model.keras # Pre-trained model
└── README.md # This file
GET /- Serve the main application pagePOST /process_image- Process uploaded images for uniform detection
- Express.js - Web framework
- Multer - File upload handling
- Sharp - Image processing
- OpenCV4Node.js - Computer vision library
- TensorFlow.js - Machine learning library
- Users can upload images or capture photos using their device camera
- Images are processed using a pre-trained TensorFlow model
- The model detects whether a person in the image is wearing a uniform
- Results are displayed with confidence scores and visual indicators
This project was converted from a Flask application. Key changes include:
- Replaced Flask routes with Express.js endpoints
- Converted Python image processing to Node.js equivalents
- Maintained the same frontend interface and functionality
- Preserved the same API contract for frontend compatibility