This repository contains code for metric learning-based recognition using PyTorch. Metric learning is a technique for learning similarity or distance metrics between data points. In the context of recognition, it helps improve the classification accuracy, especially in cases with imbalanced datasets and few-shot learning scenarios.
- Extract embeddings from images using pre-trained models.
- Train the recognition model.
- Add new classes to the existing model and update embeddings.
Before running the code, make sure you have the following dependencies installed:
- PyTorch
- PyTorch Metric Learning
- torchvision
- Pillow (PIL)
You can install the required packages using the following command:
pip install -r requirements.txt
Feel free to contribute to this project by opening issues or pull requests. Your feedback and contributions are welcome.