Skip to content
ModelListedExternal
Download

Retail Heat Osnet

Our pretrained OSNet x1.0 model for pedestrian re-identification, trained on the Market-1501 dataset. This model powers the appearance-based matching in our RetailHeat multi-object tracking pipeline.

KindOtherVersionOsnet x1 0 market1501Cgrade

Model source

Kind
Other
File size
9.92 MB
Version
vOsnet x1 0 market1501
Updated
Nov 2, 2026
Source
Hugging Face

Source description

OSNet x1.0 — Pretrained for Person Re-Identification

Our pretrained OSNet x1.0 model for pedestrian re-identification, trained on the Market-1501 dataset. This model powers the appearance-based matching in our RetailHeat multi-object tracking pipeline.

Model Details

PropertyValue
ArchitectureOSNet x1.0 (Omni-Scale Network)
Parameters2.2 M
Embedding dim512-D (L2-normalized)
Input size256 × 128 (H × W)
Training datasetMarket-1501 (12,936 training images, 751 identities)
TaskPerson re-identification

Performance

MetricValue
Rank-1 Accuracy94.2%
mAP82.6%

Architecture

OSNet (Omni-Scale Network) is a lightweight CNN designed for person re-identification. It uses omni-scale feature learning to capture discriminative features at multiple spatial scales through a unified aggregation gate. The x1.0 variant provides the best accuracy–efficiency trade-off with only 2.2M parameters, making it suitable for real-time tracking applications.

Training

We trained this model on the Market-1501 person re-identification benchmark:

  • Dataset: Market-1501 — 32,668 bounding boxes of 1,501 identities captured from 6 cameras
  • Training split: 12,936 images of 751 identities
  • Query/Gallery: 19,732 images of 750 identities
  • Optimizer: AMSGrad with learning rate warm-up and cosine annealing
  • Augmentations: Random horizontal flip, random erasing, color jitter
  • Loss: Cross-entropy + triplet loss with hard mining

Usage

Download the weights

pip install huggingface_hub
huggingface-cli download MYerassyl/retail-heat-osnet osnet_x1_0_market1501.pth --local-dir weights/

Load in Python

import torch
from torchvision import transforms

# Build OSNet model
from reid_embedder import ReIDEmbedder

embedder = ReIDEmbedder(
    model_name="osnet_x1_0",
    model_path="weights/osnet_x1_0_market1501.pth",
    image_size=(256, 128),
)

# Extract embedding from a cropped person image
embedding = embedder.extract(person_crop)  # returns 512-D L2-normalized vector

Use with the RetailHeat pipeline

This model is used as the appearance encoder in the DeepSORT tracker within our RetailHeat pipeline for retail customer tracking and heatmap generation.

git clone https://github.com/MYerassyl/retail-heat.git
cd retail-heat
mkdir -p weights
huggingface-cli download MYerassyl/retail-heat-osnet osnet_x1_0_market1501.pth --local-dir weights/
python run_pipeline.py

Citation

If you use this model, please cite our RetailHeat project:

@software{retail_heat,
  author = {Yerassyl},
  title = {RetailHeat: Multi-Object Tracking and Heatmap Generation for Retail Analytics},
  url = {https://github.com/MYerassyl/retail-heat}
}

License

This model is released under the MIT License.

Sources

1 source
Hugging FacePrimaryVersion cf0368a7d1c6baaabe8d66fe86fd221fd8b14afe
huggingface.co/MYerassyl/retail-heat-osnet/tree/cf0368a7d1c6baaabe8d66fe86fd221fd8b14afe

Verified Nov 2

Model artifacts

1 artifact

osnet_x1_0_market1501.pth

pth · 9.92 MB · SHA-256 2809d3227f7d…9154 · Hugging Face

Download file

Source excerpts

2 excerpts

--- license: mit tags: - person-reid - pedestrian-reidentification - osnet - retail-analytics - pytorch datasets: - Market-1501 metrics: - accuracy pipeline_tag: image-feature-extraction --- # OSNet x1.0 — Pretrained for Person Re-Identification Our pretrained **OSNet x1.0** model for pedestrian re-identification, trained on the [Market-1501](https://www.cv-foundation.org/openaccess/content_iccv_2015/papers/Zheng_Scalable_Person_Re-Identification_ICCV_2015_paper.pdf) dataset. This model powers the appearance-based matching in our [RetailHeat](https://github.com/MYerassyl/retail-heat) multi-object tracking pipeline. ## Model Details | Property | Value | |---|---| | **Architecture** | OSNet x1.0 (Omni-Scale Network) | | **Parameters** | 2.2 M | | **Embedding dim** | 512-D (L2-normalized) | | **Input size** | 256 × 128 (H × W) | | **Training dataset** | Market-1501 (12,936 training images, 751 identities) | | **Task** | Person re-identification | ## Performance | Metric | Value | |---|---| | **Rank-1 Accuracy** | 94.2% | | **mAP** | 82.6% | ## Architecture OSNet (Omni-Scale Network) is a lightweight CNN designed for person re-identification. It uses omni-scale feature learning to capture discriminative features at multiple spatial scales through a unified aggregation gate. The x1.0 variant provides the best accuracy–efficiency trade-off with only 2.2M parameters, making it suitable for real-time tracking applications. ## Training We trained this model on the Market-1501 person re-identification benchmark: - **Dataset**: Market-1501 — 32,668 bounding boxes of 1,501 identities captured from 6 cameras - **Training split**: 12,936 images of 751 identities - **Query/Gallery**: 19,732 images of 750 identities - **Optimizer**: AMSGrad with learning rate warm-up and cosine annealing - **Augmentations**: Random horizontal flip, random erasing, color jitter - **Loss**: Cross-entropy + triplet loss with hard mining ## Usage ### Download the weights ```bash pip install huggingface_hub huggingface-cli download MYerassyl/retail-heat-osnet osnet_x1_0_market1501.pth --local-dir weights/ ``` ### Load in Python ```python import torch from torchvision import transforms # Build OSNet model from reid_embedder import ReIDEmbedder embedder = ReIDEmbedder( model_name="osnet_x1_0", model_path="weights/osnet_x1_0_market1501.pth", image_size=(256, 128), )...

Source context: 0 downloads · 0 likes · Pipeline image-feature-extraction · Repo MYerassyl/retail-heat-osnet