Code reproduce for paper "Vehicle Re-identification with Viewpoint-aware Metric Learning"

Related tags

Deep LearningVANET
Overview

VANET

Code reproduce for paper "Vehicle Re-identification with Viewpoint-aware Metric Learning"

Introduction

This is the implementation of article VANet "Vehicle Re-identification with Viewpoint-aware Metric Learning", which support both single-branch training and two branch training.

Implementation details

The whole implementation is based on PVEN project(https://github.com/silverbulletmdc/PVEN). The key code block added and modified are mainly distributed as follows:

For network construction:
    This project provide two version of backbone, namely 'googlenet' and 'resnet50' respectively. There the corresponding configuration files 
    as well as other corresponding code interfence are all provided completely.
    code location: vehicle_reid_pytorch/models/vanet.py

For training:
    This project provide two mode of training, namely 'single branch(baseline of VANet)' and 'two branch(VANet)' respectively
    code location: examples/parsing_reid/main_vanet_single_branch.py
    code location: examples/parsing_reid/main_vanet_two_branch.py

Configuration files:
    code location: examples/parsing_reid/configs/veri776_b64_baseline_vanet_single_branch_resnet.yml
    code location: examples/parsing_reid/configs/veri776_b64_baseline_vanet_two_branch_resnet.yml
    code location: examples/parsing_reid/configs/veri776_b64_baseline_vanet_two_branch_googlenet.yml

For loss calculation:
    code location: vehicle_reid_pytorch/loss/triplet_loss.py

For evaluation:
    mAP, cmc, ..., hist distribution figure drawing function are included.
    code location: examples/parsing_reid/math_tools.py

Results comparasion

We have achieved the following preformance by using the method this paper 'VANET' provided.

     -------------------------- -----------------------------------
                  |    mAP    |   rank-1  |   rank-5  |  rank-10  |
     --------------------------------- ----------------------------
      VANET+BOT   |   80.1%   |   96.5    |   98.5    |    99.4   | 
     --------------------------------------------------------------
      BOT(ours)   |   77.8%   |   95.3    |   97.8    |    98.8   |
     --------------------------------------------------------------
      BOT[1]      |   78.2%   |   95.5    |   97.9    |      *    |
     --------------------------------------------------------------

Note: The 'BOT', which means "bag of tricks" proposed by paper[2]. With respect to the two branch implementation of the above "VANET+BOT", we adopted the first 6 layers of the official resnet50 as the shared_conv network, the remaining two layers as the branch_conv network.There are also instructions in the corresponding code when you use.

Also, four type data's(similar-view_same-id, similar-view_different-id, different-view_different-id, different-view_same-id) distribution are drawn based on paper's aspect. note: this visualization code can be founded at examples/parsing_reid/math_tools.py

1. Get started

All the results are tested on VeRi-776 dstasets. Please reference to the environment implementation of other general reid projects, this project reference to fast-reid's.

2. Training

Reference to folder run_sh/run_main_XXX.sh Note: If you want to use your own dataset for training, remember to keep your data's structure be consistent with the veri776 dataloader's output in this project, reference to realted code for more details.

Example:

  sh ./run_sh/run_main_vanet_two_branch_resnet.sh

3. evaluation

Reference to folder run_sh/run_eval_XXX.sh Note: We have add 'drawing hist graph' function in evaluated stage, if you needn't this statistic operation temporarily, remember to shut down this function, for the operation is to some extent time-consuming, detail code block are located in examples/parsing_reid/math_tools.py.

Example:

  sh ./run_sh/run_eval_two_branch_resnet.sh

reference

[1] Khorramshahi, Pirazh, et al. "The devil is in the details: Self-supervised attention for vehicle re-identification." European Conference on Computer Vision. Springer, Cham, 2020.

[2] Luo, Hao, et al. "Bag of tricks and a strong baseline for deep person re-identification." Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops. 2019.

Contact

For any question, please file an issue or contact

Shichao Liu (Shanghai Em-Data Technology Co., Ltd.) [email protected]
Owner
EMDATA-AILAB
EMDATA-AILAB
Chinese license plate recognition

AgentCLPR 简介 一个基于 ONNXRuntime、AgentOCR 和 License-Plate-Detector 项目开发的中国车牌检测识别系统。 车牌识别效果 支持多种车牌的检测和识别(其中单层车牌识别效果较好): 单层车牌: [[[[373, 282], [69, 284],

AgentMaker 26 Dec 25, 2022
Projects of Andfun Yangon

AndFunYangon Projects of Andfun Yangon First Commit We can use gsearch.py to sea

Htin Aung Lu 1 Dec 28, 2021
Deep generative modeling for time-stamped heterogeneous data, enabling high-fidelity models for a large variety of spatio-temporal domains.

Neural Spatio-Temporal Point Processes [arxiv] Ricky T. Q. Chen, Brandon Amos, Maximilian Nickel Abstract. We propose a new class of parameterizations

Facebook Research 75 Dec 19, 2022
As-ViT: Auto-scaling Vision Transformers without Training

As-ViT: Auto-scaling Vision Transformers without Training [PDF] Wuyang Chen, Wei Huang, Xianzhi Du, Xiaodan Song, Zhangyang Wang, Denny Zhou In ICLR 2

VITA 68 Sep 05, 2022
3D-Reconstruction 基于深度学习方法的单目多视图三维重建

基于深度学习方法的单目多视图三维重建 Part I 三维重建 代码:Part1 技术文档:[Markdown] [PDF] 原始图像:Original Images 点云结果:Point Cloud Results-1

HMT_Curo 19 Dec 26, 2022
A framework that constructs deep neural networks, autoencoders, logistic regressors, and linear networks

A framework that constructs deep neural networks, autoencoders, logistic regressors, and linear networks without the use of any outside machine learning libraries - all from scratch.

Kordel K. France 2 Nov 14, 2022
Code and description for my BSc Project, September 2021

BSc-Project Disclaimer: This repo consists of only the additional python scripts necessary to run the agent. To run the project on your own personal d

Matin Tavakoli 20 Jul 19, 2022
A library for Deep Learning Implementations and utils

deeply A Deep Learning library Table of Contents Features Quick Start Usage License Features Python 2.7+ and Python 3.4+ compatible. Quick Start $ pip

Achilles Rasquinha 1 Dec 12, 2022
Learning Tracking Representations via Dual-Branch Fully Transformer Networks

Learning Tracking Representations via Dual-Branch Fully Transformer Networks DualTFR ⭐ We achieves the runner-ups for both VOT2021ST (short-term) and

phiphi 19 May 04, 2022
⚓ Eurybia monitor model drift over time and securize model deployment with data validation

View Demo · Documentation · Medium article 🔍 Overview Eurybia is a Python library which aims to help in : Detecting data drift and model drift Valida

MAIF 172 Dec 27, 2022
PPLNN is a Primitive Library for Neural Network is a high-performance deep-learning inference engine for efficient AI inferencing

PPLNN is a Primitive Library for Neural Network is a high-performance deep-learning inference engine for efficient AI inferencing

943 Jan 07, 2023
A toy compiler that can convert Python scripts to pickle bytecode 🥒

Pickora 🐰 A small compiler that can convert Python scripts to pickle bytecode. Requirements Python 3.8+ No third-party modules are required. Usage us

ꌗᖘ꒒ꀤ꓄꒒ꀤꈤꍟ 68 Jan 04, 2023
😊 Python module for face feature changing

PyWarping Python module for face feature changing Installation pip install pywarping If you get an error: No such file or directory: 'cmake': 'cmake',

Dopevog 10 Sep 10, 2021
Official PyTorch implementation of BlobGAN: Spatially Disentangled Scene Representations

BlobGAN: Spatially Disentangled Scene Representations Official PyTorch Implementation Paper | Project Page | Video | Interactive Demo BlobGAN.mp4 This

148 Dec 29, 2022
Pytorch Implementation of Value Retrieval with Arbitrary Queries for Form-like Documents.

Value Retrieval with Arbitrary Queries for Form-like Documents Introduction Pytorch Implementation of Value Retrieval with Arbitrary Queries for Form-

Salesforce 13 Sep 15, 2022
[ECCV 2020] XingGAN for Person Image Generation

Contents XingGAN or CrossingGAN Installation Dataset Preparation Generating Images Using Pretrained Model Train and Test New Models Evaluation Acknowl

Hao Tang 218 Oct 29, 2022
Inference code for "StylePeople: A Generative Model of Fullbody Human Avatars" paper. This code is for the part of the paper describing video-based avatars.

NeuralTextures This is repository with inference code for paper "StylePeople: A Generative Model of Fullbody Human Avatars" (CVPR21). This code is for

Visual Understanding Lab @ Samsung AI Center Moscow 18 Oct 06, 2022
Sound and Cost-effective Fuzzing of Stripped Binaries by Incremental and Stochastic Rewriting

StochFuzz: A New Solution for Binary-only Fuzzing StochFuzz is a (probabilistically) sound and cost-effective fuzzing technique for stripped binaries.

Zhuo Zhang 164 Dec 05, 2022
git《Tangent Space Backpropogation for 3D Transformation Groups》(CVPR 2021) GitHub:1]

LieTorch: Tangent Space Backpropagation Introduction The LieTorch library generalizes PyTorch to 3D transformation groups. Just as torch.Tensor is a m

Princeton Vision & Learning Lab 482 Jan 06, 2023
Multiview 3D object detection on MultiviewC dataset through moft3d.

Voxelized 3D Feature Aggregation for Multiview Detection [arXiv] Multiview 3D object detection on MultiviewC dataset through VFA. Introduction We prop

Jiahao Ma 20 Dec 21, 2022