Code Monkey home page Code Monkey logo

metriclearningbench's Introduction

Metric learning models in PyTorch, recall@1

CUB2011 CARS196 Stanford Online Products
Margin contrastive loss, semi-hard 0.58 @ epoch60 0.80 @ epoch60 0.7526 @ epoch90
Lifted structured embedding
Triplet loss

Original impl of Margin contrastive loss published at: https://github.com/apache/incubator-mxnet/tree/19ede063c4756fa49cfe741e654180aee33991c6/example/gluon/embedding_learning (temporarily removed in apache/mxnet#20602)

Examples

# evaluation results are saved in ./data/log.txt

# train margin contrastive loss on CUB2011 using ResNet-50
python train.py --dataset cub2011 --model margin --base resnet50

# download GoogLeNet weights and train using LiftedStruct loss
wget -P ./data https://github.com/vadimkantorov/metriclearningbench/releases/download/data/googlenet.h5
python train.py --dataset cub2011 --model liftedstruct --base inception_v1_googlenet

# evaluate raw final layer embeddings on CUB2011 using ResNet-50
python train.py --dataset cub2011 --model untrained  --epochs 1

metriclearningbench's People

Contributors

vadimkantorov avatar

Watchers

paper2code - bot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.