YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

Banknote Embedder

Fine-tuned visual embedding model for Nepali banknotes.

It maps an input banknote image to a 512-d normalized embedding vector.
You can compare two notes using cosine similarity:

  • higher score -> more similar
  • lower score -> less similar

Model Files

  • banknote_embedder_finetuned.pth: training state_dict
  • banknote_embedder_fp16.safetensors: compressed inference weights (recommended)
  • banknote_embedder_int8_dynamic.pth: dynamic int8 export for supported CPU backends

Quantize / Export

Generate compressed artifacts from your fine-tuned weights:

python quantize_model.py --input-model banknote_embedder_finetuned.pth --skip-int8

Outputs:

  • banknote_embedder_fp16.safetensors

Optional (if your CPU backend supports it):

python quantize_model.py --input-model banknote_embedder_finetuned.pth

Additional output:

  • banknote_embedder_int8_dynamic.pth

Quick Test

Run similarity test:

python test.py --weights banknote_embedder_fp16.safetensors --img1 notes/20.jpg --img2 notes/20.jpg --img3 notes/22.jpg

Expected behavior:

  • img1 vs img2 should be high (often close to 1.0 for identical image)
  • img1 vs img3 should be lower

Usage Notes

  • Input preprocessing uses ImageNet normalization and 224x224 resize.
  • Embeddings are L2-normalized in the model forward pass.
  • xFormers is not available warnings are expected and non-fatal.
Downloads last month

-

Downloads are not tracked for this model. How to track
Safetensors
Model size
1B params
Tensor type
F32
·
I8
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support