A collection of implementations of deep domain adaptation algorithms

Overview

Deep Transfer Learning on PyTorch

MIT License

This is a PyTorch library for deep transfer learning. We divide the code into two aspects: Single-source Unsupervised Domain Adaptation (SUDA) and Multi-source Unsupervised Domain Adaptation (MUDA). There are many SUDA methods, however I find there is a few MUDA methods with deep learning. Besides, MUDA with deep learning might be a more promising direction for domain adaptation.

Here I have implemented some deep transfer methods as follows:

  • UDA
    • DDC:Deep Domain Confusion Maximizing for Domain Invariance
    • DAN: Learning Transferable Features with Deep Adaptation Networks (ICML2015)
    • Deep Coral: Deep CORAL Correlation Alignment for Deep Domain Adaptation (ECCV2016)
    • Revgrad: Unsupervised Domain Adaptation by Backpropagation (ICML2015)
    • MRAN: Multi-representation adaptation network for cross-domain image classification (Neural Network 2019)
    • DSAN: Deep Subdomain Adaptation Network for Image Classification (IEEE Transactions on Neural Networks and Learning Systems 2020)
  • MUDA
    • Aligning Domain-specific Distribution and Classifier for Cross-domain Classification from Multiple Sources (AAAI2019)
  • Application
    • Cross-domain Fraud Detection: Modeling Users’ Behavior Sequences with Hierarchical Explainable Network for Cross-domain Fraud Detection (WWW2020)
    • Learning to Expand Audience via Meta Hybrid Experts and Critics for Recommendation and Advertising (KDD2021)
  • Survey

Results on Office31(UDA)

Method A - W D - W W - D A - D D - A W - A Average
ResNet 68.4±0.5 96.7±0.5 99.3±0.1 68.9±0.2 62.5±0.3 60.7±0.3 76.1
DDC 75.8±0.2 95.0±0.2 98.2±0.1 77.5±0.3 67.4±0.4 64.0±0.5 79.7
DDC* 78.3±0.4 97.1±0.1 100.0±0.0 81.7±0.9 65.2±0.6 65.1±0.4 81.2
DAN 83.8±0.4 96.8±0.2 99.5±0.1 78.4±0.2 66.7±0.3 62.7±0.2 81.3
DAN* 82.6±0.7 97.7±0.1 100.0±0.0 83.1±0.9 66.8±0.3 66.6±0.4 82.8
DCORAL* 79.0±0.5 98.0±0.2 100.0±0.0 82.7±0.1 65.3±0.3 64.5±0.3 81.6
Revgrad 82.0±0.4 96.9±0.2 99.1±0.1 79.7±0.4 68.2±0.4 67.4±0.5 82.2
Revgrad* 82.6±0.9 97.8±0.2 100.0±0.0 83.3±0.9 66.8±0.1 66.1±0.5 82.8
MRAN 91.4±0.1 96.9±0.3 99.8±0.2 86.4±0.6 68.3±0.5 70.9±0.6 85.6
DSAN 93.6±0.2 98.4±0.1 100.0±0.0 90.2±0.7 73.5±0.5 74.8±0.4 88.4

Note that the results without '*' comes from paper. The results with '*' are run by myself with the code.

Results on Office31(MUDA)

Standards Method A,W - D A,D - W D,W - A Average
ResNet 99.3 96.7 62.5 86.2
DAN 99.5 96.8 66.7 87.7
Single Best DCORAL 99.7 98.0 65.3 87.7
RevGrad 99.1 96.9 68.2 88.1
DAN 99.6 97.8 67.6 88.3
Source Combine DCORAL 99.3 98.0 67.1 88.1
RevGrad 99.7 98.1 67.6 88.5
Multi-Source MFSAN 99.5 98.5 72.7 90.2

Results on OfficeHome(MUDA)

Standards Method C,P,R - A A,P,R - C A,C,R - P A,C,P - R Average
ResNet 65.3 49.6 79.7 75.4 67.5
DAN 64.1 50.8 78.2 75.0 67.0
Single Best DCORAL 68.2 56.5 80.3 75.9 70.2
RevGrad 67.9 55.9 80.4 75.8 70.0
DAN 68.5 59.4 79.0 82.5 72.4
Source Combine DCORAL 68.1 58.6 79.5 82.7 72.2
RevGrad 68.4 59.1 79.5 82.7 72.4
Multi-Source MFSAN 72.1 62.0 80.3 81.8 74.1

Note that (1) Source combine: all source domains are combined together into a traditional single-source v.s. target setting. (2) Single best: among the multiple source domains, we report the best single source transfer results. (3) Multi-source: the results of MUDA methods.

Note

If you find that your accuracy is 100%, the problem might be the dataset folder. Please note that the folder structure required for the data provider to work is:

-dataset
    -amazon
    -webcam
    -dslr

Contact

If you have any problem about this library, please create an Issue or send us an Email at:

Reference

If you use this repository, please cite the following papers:

@inproceedings{zhu2019aligning,
  title={Aligning domain-specific distribution and classifier for cross-domain classification from multiple sources},
  author={Zhu, Yongchun and Zhuang, Fuzhen and Wang, Deqing},
  booktitle={Proceedings of the AAAI Conference on Artificial Intelligence},
  volume={33},
  pages={5989--5996},
  year={2019}
}
@article{zhu2020deep,
  title={Deep Subdomain Adaptation Network for Image Classification},
  author={Zhu, Yongchun and Zhuang, Fuzhen and Wang, Jindong and Ke, Guolin and Chen, Jingwu and Bian, Jiang and Xiong, Hui and He, Qing},
  journal={IEEE Transactions on Neural Networks and Learning Systems},
  year={2020},
  publisher={IEEE}
}
Owner
Yongchun Zhu
ICT Yongchun Zhu
Yongchun Zhu
Official repository for GCR rerank, a GCN-based reranking method for both image and video re-ID

Official repository for GCR rerank, a GCN-based reranking method for both image and video re-ID

53 Nov 22, 2022
Official PyTorch implementation of the preprint paper "Stylized Neural Painting", accepted to CVPR 2021.

Official PyTorch implementation of the preprint paper "Stylized Neural Painting", accepted to CVPR 2021.

Zhengxia Zou 1.5k Dec 28, 2022
House_prices_kaggle - Predict sales prices and practice feature engineering, RFs, and gradient boosting

House Prices - Advanced Regression Techniques Predicting House Prices with Machine Learning This project is build to enhance my knowledge about machin

Gurpreet Singh 1 Jan 01, 2022
WORD: Revisiting Organs Segmentation in the Whole Abdominal Region

WORD: Revisiting Organs Segmentation in the Whole Abdominal Region (Paper and DataSet). [New] Note that all the emails about the download permission o

Healthcare Intelligence Laboratory 71 Dec 22, 2022
Arxiv harvester - Poor man's simple harvester for arXiv resources

Poor man's simple harvester for arXiv resources This modest Python script takes

Patrice Lopez 5 Oct 18, 2022
Official implementation of "Dynamic Anchor Learning for Arbitrary-Oriented Object Detection" (AAAI2021).

DAL This project hosts the official implementation for our AAAI 2021 paper: Dynamic Anchor Learning for Arbitrary-Oriented Object Detection [arxiv] [c

ming71 215 Nov 28, 2022
Lightweight, Portable, Flexible Distributed/Mobile Deep Learning with Dynamic, Mutation-aware Dataflow Dep Scheduler; for Python, R, Julia, Scala, Go, Javascript and more

Apache MXNet (incubating) for Deep Learning Master Docs License Apache MXNet (incubating) is a deep learning framework designed for both efficiency an

ROCm Software Platform 29 Nov 16, 2022
A curated list of awesome papers for Semantic Retrieval (TOIS Accepted: Semantic Models for the First-stage Retrieval: A Comprehensive Review).

A curated list of awesome papers for Semantic Retrieval (TOIS Accepted: Semantic Models for the First-stage Retrieval: A Comprehensive Review).

Yinqiong Cai 189 Dec 28, 2022
Face Recognition Attendance Project

Face-Recognition-Attendance-Project In This Project You will learn how to mark attendance using face recognition, Hello Guys This is Gautam Kumar, Thi

Gautam Kumar 1 Dec 03, 2022
A cross-lingual COVID-19 fake news dataset

CrossFake An English-Chinese COVID-19 fake&real news dataset from the ICDMW 2021 paper below: Cross-lingual COVID-19 Fake News Detection. Jiangshu Du,

Yingtong Dou 11 Dec 01, 2022
Code for ACM MM 2020 paper "NOH-NMS: Improving Pedestrian Detection by Nearby Objects Hallucination"

NOH-NMS: Improving Pedestrian Detection by Nearby Objects Hallucination The offical implementation for the "NOH-NMS: Improving Pedestrian Detection by

Tencent YouTu Research 64 Nov 11, 2022
A high-performance Python-based I/O system for large (and small) deep learning problems, with strong support for PyTorch.

WebDataset WebDataset is a PyTorch Dataset (IterableDataset) implementation providing efficient access to datasets stored in POSIX tar archives and us

1.1k Jan 08, 2023
Code repository for Self-supervised Structure-sensitive Learning, CVPR'17

Self-supervised Structure-sensitive Learning (SSL) Ke Gong, Xiaodan Liang, Xiaohui Shen, Liang Lin, "Look into Person: Self-supervised Structure-sensi

Clay Gong 219 Dec 29, 2022
Repo for FUZE project. I will also publish some Linux kernel LPE exploits for various real world kernel vulnerabilities here. the samples are uploaded for education purposes for red and blue teams.

Linux_kernel_exploits Some Linux kernel exploits for various real world kernel vulnerabilities here. More exploits are yet to come. This repo contains

Wei Wu 472 Dec 21, 2022
Library for machine learning stacking generalization.

stacked_generalization Implemented machine learning *stacking technic[1]* as handy library in Python. Feature weighted linear stacking is also availab

114 Jul 19, 2022
An official implementation of "Exploiting a Joint Embedding Space for Generalized Zero-Shot Semantic Segmentation" (ICCV 2021) in PyTorch.

Exploiting a Joint Embedding Space for Generalized Zero-Shot Semantic Segmentation This is an official implementation of the paper "Exploiting a Joint

CV Lab @ Yonsei University 35 Oct 26, 2022
Prometheus exporter for Cisco Unified Computing System (UCS) Manager

prometheus-ucs-exporter Overview Use metrics from the UCS API to export relevant metrics to Prometheus This repository is a fork of Drew Stinnett's or

Marshall Wace 6 Nov 07, 2022
Official Implementation of CoSMo: Content-Style Modulation for Image Retrieval with Text Feedback

CoSMo.pytorch Official Implementation of CoSMo: Content-Style Modulation for Image Retrieval with Text Feedback, Seungmin Lee*, Dongwan Kim*, Bohyung

Seung Min Lee 54 Dec 08, 2022
patchmatch和patchmatchstereo算法的python实现

patchmatch patchmatch以及patchmatchstereo算法的python版实现 patchmatch参考 github patchmatchstereo参考李迎松博士的c++版代码 由于patchmatchstereo没有做任何优化,并且是python的代码,主要是方便解析算

Sanders Bao 11 Dec 02, 2022
😊 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