All Projects → littleredxh → DREML

littleredxh / DREML

Licence: other
PyTorch implementation of Deep Randomized Ensembles for Metric Learning(ECCV2018)

Programming Languages

python
139335 projects - #7 most used programming language
Jupyter Notebook
11667 projects
shell
77523 projects

Projects that are alternatives of or similar to DREML

tf retrieval baseline
A Tensorflow retrieval (space embedding) baseline. Metric learning baseline on CUB and Stanford Online Products.
Stars: ✭ 39 (-41.79%)
Mutual labels:  embedding, retrieving-images
Siamese Triplet
Siamese and triplet networks with online pair/triplet mining in PyTorch
Stars: ✭ 2,564 (+3726.87%)
Mutual labels:  embedding
text-classification-cn
中文文本分类实践,基于搜狗新闻语料库,采用传统机器学习方法以及预训练模型等方法
Stars: ✭ 81 (+20.9%)
Mutual labels:  embedding
XLNet embbeding
Using XLNet as Embedding of Keras
Stars: ✭ 32 (-52.24%)
Mutual labels:  embedding
nodebb-plugin-ns-embed
Embed media and rich content in posts: YouTube, Vimeo, Twitch and more.
Stars: ✭ 27 (-59.7%)
Mutual labels:  embedding
TransE-Knowledge-Graph-Embedding
TensorFlow implementation of TransE and its extended models for Knowledge Representation Learning
Stars: ✭ 64 (-4.48%)
Mutual labels:  embedding
playing with vae
Comparing FC VAE / FCN VAE / PCA / UMAP on MNIST / FMNIST
Stars: ✭ 53 (-20.9%)
Mutual labels:  embedding
fastwalk
A multi-thread implementation of node2vec random walk.
Stars: ✭ 24 (-64.18%)
Mutual labels:  embedding
Awesome Community Detection
A curated list of community detection research papers with implementations.
Stars: ✭ 1,874 (+2697.01%)
Mutual labels:  embedding
FSCNMF
An implementation of "Fusing Structure and Content via Non-negative Matrix Factorization for Embedding Information Networks".
Stars: ✭ 16 (-76.12%)
Mutual labels:  embedding
Embedding
Embedding模型代码和学习笔记总结
Stars: ✭ 25 (-62.69%)
Mutual labels:  embedding
walklets
A lightweight implementation of Walklets from "Don't Walk Skip! Online Learning of Multi-scale Network Embeddings" (ASONAM 2017).
Stars: ✭ 94 (+40.3%)
Mutual labels:  embedding
Milvus
An open-source vector database for embedding similarity search and AI applications.
Stars: ✭ 9,015 (+13355.22%)
Mutual labels:  embedding
BERT-embedding
A simple wrapper class for extracting features(embedding) and comparing them using BERT in TensorFlow
Stars: ✭ 24 (-64.18%)
Mutual labels:  embedding
Cool-NLPCV
Some Cool NLP and CV Repositories and Solutions (收集NLP中常见任务的开源解决方案、数据集、工具、学习资料等)
Stars: ✭ 143 (+113.43%)
Mutual labels:  embedding
AnnA Anki neuronal Appendix
Using machine learning on your anki collection to enhance the scheduling via semantic clustering and semantic similarity
Stars: ✭ 39 (-41.79%)
Mutual labels:  embedding
pymde
Minimum-distortion embedding with PyTorch
Stars: ✭ 420 (+526.87%)
Mutual labels:  embedding
NMFADMM
A sparsity aware implementation of "Alternating Direction Method of Multipliers for Non-Negative Matrix Factorization with the Beta-Divergence" (ICASSP 2014).
Stars: ✭ 39 (-41.79%)
Mutual labels:  embedding
keras-pos-embd
Position embedding layers in Keras
Stars: ✭ 61 (-8.96%)
Mutual labels:  embedding
-Online-Soft-Mining-and-Class-Aware-Attention-Pytorch
(Pytorch and Tensorflow) Implementation of Weighted Contrastive Loss (Deep Metric Learning by Online Soft Mining and Class-Aware Attention)
Stars: ✭ 20 (-70.15%)
Mutual labels:  deep-metric-learning

New approach for better retrieval performance with single model: Improved Embeddings with Easy Positive Triplet Mining(WACV2020)

Paper link: https://arxiv.org/abs/1904.04370

Git link: https://github.com/littleredxh/EasyPositiveHardNegative

Deep Randomized Ensembles for Metric Learning

This repository contains the PyTorch(1.5.0) implementation of Deep Randomized Ensembles for Metric Learning(ECCV2018)

Paper link: https://arxiv.org/abs/1808.04469 or https://www2.seas.gwu.edu/~pless/papers/DREML_ECCV2018.pdf

Prepare the training data and testing data in python dictionary format.

For example:

data_dict = {'tra' : {'class_tra_01':[image path list],
                      'class_tra_02':[image path list],
                      'class_tra_03':[image path list],
                      ....,
                      'class_tra_XX':[image path list]}
                 
             'test': {'class_test_01':[image path list],
                      'class_test_02':[image path list],
                      'class_test_03':[image path list],
                      ....,
                      'class_test_XX':[image path list]}
            }

Replace Data and data_dict in the file main.py

We have the color nomarlization info for CUB, CAR, SOP, CIFAR100, In-shop cloth and PKU vehicleID data. If you want to use other dataset please add the color nomarlization value in _code/color_lib.py

We also provide efficient recall@K accuracy calculation functions in _code/Utils.py

Function for CAR,CUB and SOP dataset:recall(Fvec, imgLab, rank=None) 
Fvec:   Feature vectors, N by D torch.Tensor
imgLab: Image label, python list
rank:   k of recall@k, python list

Function for In-shop Cloth dataset: recall2(Fvec_val, Fvec_gal, imgLab_val, imgLab_gal, rank=None) 
Fvec_val:     Probe feature vectors, N_val by D torch.Tensor
Fvec_gal:     Gallary feature vectors, N_gal by D torch.Tensor
imgLab_val:   Probe image label, python list
imgLab_gal:   Gallary image label, python list
rank:         k of recall@k, python list

The example of calling the function is shown in Recall.ipynb

Please cite our paper, if you use these functions for recall calculation.

Requirements

Pytorch 1.5.0

Python >3.5

Updates

06/12/2020/: Upgrade to PyTorch 1.5.0 version

05/01/2019/:

Upgrade to PyTorch 1.0.0 version

Simplified the codes structure

Fix the bug in Recall.ipynb

Add recall functions for CAR, CUB, SOP and In-shop cloth dataset

Citation

@InProceedings{Xuan_2018_ECCV,
author = {Xuan, Hong and Souvenir, Richard and Pless, Robert},
title = {Deep Randomized Ensembles for Metric Learning},
booktitle = {The European Conference on Computer Vision (ECCV)},
month = {September},
year = {2018}
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].