ONNX Model Zoo

abhi099k/image-multi-detect

By abhi099k · ↓ 0 · ♥ 0 · Updated 2025-11-19

What's in this repo

This page lists the files in abhi099k/image-multi-detect, including model.onnx.

  • 1 ONNX models (.onnx files)
  • 5 files, including 2 .json, 1 .md, 1 .onnx
  • Last updated 2025-11-19

ONNX files

File Size Download
model.onnx — Download

How to use

These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.

README

🖼️ Image Multi-Label Safety Classifier

Repo: abhi099k/image-multi-detect
Framework: PyTorch + ONNX
Task: Multi-label image content classification
Author: Abhinav


🚀 Overview

This model is a professional multi-label image classifier trained to detect multiple safety-related categories simultaneously.
It is optimized for:

  • NSFW / adult content detection
  • Violence
  • Weapons
  • Substance categories (smoking, alcohol, drugs)
  • Sensitive content
  • Hate content

The model supports 8 independent labels, using sigmoid (multi-label) rather than softmax.


🧠 Labels

Index Label Meaning
0 nsfw Nude/sexual content
1 violence Physical harm, fighting, blood
2 weapon Guns, knives, explosives
3 smoking Cigarettes, vaping, smoking activity
4 alcohol Alcoholic drinks or consumption
5 drugs Illegal drugs, pills, paraphernalia
6 sensitive Sensitive contexts (medical, blood, etc.)
7 hate Hateful symbols, extremist logos

📦 Files in Repository

File Description
best.pth PyTorch model weights
model.onnx ONNX-exported model (recommended for inference)
metrics_test.json Evaluation results
history.json Training logs

🔧 Technical Details

Architecture

  • Backbone: ResNet-50
  • Head: Fully connected layer → 8 logits
  • Loss: BCEWithLogitsLoss
  • Optimizer: AdamW
  • Mixed precision: Yes
  • Balanced sampling: WeightedRandomSampler

Image Size

224 × 224

Training Transformations

  • Resize
  • Random crop
  • Horizontal flip
  • Color jitter
  • Normalization

📈 Performance

Macro-averaged metrics on test set:

Model info

onnx license:mit region:us
↓ 0 ♥ 0

Created: 2025-11-18

Updated: 2025-11-19

View on Hugging Face

Files (5)

.gitattributes
README.md
history.json
metrics_test.json
model.onnx ONNX

Related models