Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Ultra-lightweight (600KB) Face Anti-Spoofing classifier. Optimized MiniFASNetV2-SE implementation validated on 70k+ samples with ~98% accuracy for edge devices.
| Date | Stars |
|---|---|
| 2026-07-24 | 249 |
| 2026-07-25 | 249 |
| 2026-07-28 | 251 |
| 2026-07-30 | 251 |
| 2026-08-06 | 251 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
<div align="center"> # Lightweight Face Antispoof (MiniFAS, ONNX) [](LICENSE) [](https://www.python.org/) [](https://pytorch.org/) [](https://onnx.ai/)  </div> A lightweight face anti-spoofing model that distinguishes real faces from spoofing attempts (printed photos, screen displays, etc.). ### Performance Demo > **Note:** The demo above was recorded on legacy hardware to showcase the model's efficiency on low-spec devices. | Metric | Details | | :--- | :--- | | **CPU** | Intel® Core™ i7-2630QM @ 2.00GHz (4C/8T) | | **GPU** | None (Inference run on CPU) | --- ## Model The trained model is a tiny classifier that predicts two classes: **Real** or **Spoof**. | ONNX | Quantized ONNX | PyTorch | Input | Arch | |:---------:|:---------------:|:------------:|:-----:|:------------:| | 1.82 MB | **600 KB** | 1.95 MB | 128×128 RGB | MiniFAS | ### Model Performance | Metric | Model | Quantized | |:-------|:-----:|:---------:| | **Model Size** | 1.82 MB | **600 KB** | | **Overall Accuracy** | **98.20%** | **98.20%** | | Real Accuracy | 97.58% | 97.55% | | Spoof Accuracy | 98.73% | 98.73% | | **ROC-AUC** | **0.9984** | **0.9984** | | **Average Precision** | **0.9987** | **0.9987** | > Tested on CelebA Spoof (70k+ samples). Quantization has no accuracy drop. **[Detailed metrics →](docs/METRICS.md)** | **[Previous results →](docs/PREVIOUS_RESULTS.md)** --- ## Pre-trained Pre-trained models are available in the `models/` directory: | Model | Size | Format | Use Case | |:------|:----:|:------:|:---------| | `best_model.pth` | 1.95 MB | PyTorch | Training, fine-tuning, PyTorch inference | | `best_model.onnx` | 1.82 MB | ONNX | General deployment, cross-platform inference | | `best_model_quantized.onnx` | **600 KB** | ONNX (INT8) | **Production deployment** | --- ## Why MiniFAS? The first version used MobileNetV4 (still in `src/mobilenetv4` for reference). It worked, but the model was larger than necessary and the training was more complex. MiniFAS turned out to be a better fit: - Smaller model, faster inference - Built specifically for anti-spoofing, not a general-purpose backbone - Uses Fourier Transform auxiliary loss during training—this helps the model learn frequency-domain patterns that distinguish real skin texture from printed photos and screen displays - SE (Squeeze-and-Excitation) blocks for adaptive channel attention > The MobileNetV4 code remains in `src/mobilenetv4/` for future experiments and reference. All current training uses MiniFASNet V2 SE. **[Architecture details →](docs/ARCHITECTURE.md)** --- ## Quick Start ### 1. Create and activate a virtual environment (Recommended) **Using Conda:** ```bash conda create -n face-antispoof python conda activate face-antispoof ``` **OR using venv:** ```bash python -m venv venv # Linux/macOS source venv/bin/activate # Windows venv\Scripts\activate ``` ### 2. Install dependencies ```bash pip install -r requirements.txt ``` > [!IMPORTANT] > **Python Version:** This project requires **Python 3.8.0 or higher**. ### Compatibility Note: Python 3.7.x Tested on **Python 3.7.16** and was confirmed that they are **not compatible**. Attempting to install dependencies on Python 3.7.x will result in a `subprocess-exited-with-error` during the `pip` installation of backend dependencies. **Error Example:** ```text ERROR: Ignored the following versions that require a different python version: 0.1.0 Requires-Python >=3.9; ... ERROR: Could not find a version that satisfies the requirement puccinialin ERROR: No matching distribution found for puccinialin ``` > **Note:** To run on GPU, install `onnxruntime-gpu` instead of `onnxruntime`. ### Run the Demo **Webcam:** ```bash python demo.py ``` or ```bash pyth
Excerpt of 6,804 characters
Read on GitHubWould you bet a product on this? Bounded 0–100 and slow moving.
matched fp:19561e2e12613a47, topic:computer-vision, topic:opencv
matched fp:19561e2e12613a47, topic:onnx
matched fp:19561e2e12613a47, topic:pytorch