Git Product home page Git Product logo

2022-tpami-dcp's Introduction

Dual Contrastive Prediction for Incomplete Multi-view Representation Learning

This repo contains the code and data of our IEEE TPAMI'2022 paper Dual Contrastive Prediction for Incomplete Multi-view Representation Learning. Precise numerical results of different missing rates could be accessed from Results_missing_rate.xlsx.

Dual Contrastive Prediction for Incomplete Multi-view Representation Learning

COMPLETER: Incomplete Multi-view Clustering via Contrastive Prediction

framework

Requirements

pytorch>=1.2.0

numpy>=1.19.1

scikit-learn>=0.23.2

munkres>=1.1.4

Configuration

The hyper-parameters, the training options are defined in the configure folder.

  • configure_clustering.py: bi-view data clustering
  • configure_clustering_multiview.py: 3-view data clustering
  • configure_supervised.py: bi-view data classification (including human action recognition)
  • configure_supervised_multiview.py: 3-view data classification

Note that for multi-view setting, we place both complete graph and cove view setting (i.e., type='CG' or 'CV' ).

Datasets

The Caltech101-20, LandUse-21, Scene-15, UWA, and DHA datasets are placed in "data" folder. The NoisyMNIST dataset could be downloaded from cloud.

Usage

The code includes:

  • an example implementation of the model. The network structure and training/evaluation pipeline are in model.py and model.multiview.py:

  • clustering tasks for different missing rates.

python run_clustering.py --dataset 0 --devices 0 --print_num 100 --test_time 5 --missing_rate 0.5
python run_clustering_multiview.py 
  • classification tasks for different missing rates.
python run_supervised.py --dataset 0 --devices 0 --print_num 100 --test_time 5 --missing_rate 0.5
python run_supervised_multiview.py
  • human action recognition tasks
python run_HAR.py 

You can get the following output by runing python run_HAR.py:

Epoch : 100/2000 ===> Reconstruction loss = 5.1242===> Reconstruction loss = 0.0489 ===> Map loss = 0.0001 ===> Map loss = 0.0001 ===> Loss_icl = -7.4860e+01 ===> Loss_ccl = 1.2800e+02 ===> All loss = 5.3657e+01
RGB   Accuracy on the test set is 0.6653
Depth Accuracy on the test set is 0.3926
RGB+D Accuracy on the test set is 0.8430
onlyRGB Accuracy on the test set is 0.6860
onlyDepth Accuracy on the test set is 0.3636
Epoch : 2000/2000 ===> Reconstruction loss = 4.3108===> Reconstruction loss = 0.0163 ===> Map loss = 0.0001 ===> Map loss = 0.0004 ===> Loss_icl = -7.7413e+01 ===> Loss_ccl = 1.2800e+02 ===> All loss = 5.1020e+01
RGB   Accuracy on the test set is 0.7769
Depth Accuracy on the test set is 0.8306
RGB+D Accuracy on the test set is 0.8926
onlyRGB Accuracy on the test set is 0.7727
onlyDepth Accuracy on the test set is 0.8182

Todo: Multi-view setting

Reference

If you find our work useful in your research, please consider citing:

@ARTICLE{9852291,
  author={Lin, Yijie and Gou, Yuanbiao and Liu, Xiaotian and Bai, Jinfeng and Lv, Jiancheng and Peng, Xi},
  journal={IEEE Transactions on Pattern Analysis and Machine Intelligence}, 
  title={Dual Contrastive Prediction for Incomplete Multi-View Representation Learning}, 
  year={2022},
  doi={10.1109/TPAMI.2022.3197238}
}
@inproceedings{lin2021completer,
   title={COMPLETER: Incomplete Multi-view Clustering via Contrastive Prediction},
   author={Lin, Yijie and Gou, Yuanbiao and Liu, Zitao and Li, Boyun and Lv, Jiancheng and Peng, Xi},
   booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
   month={June},
   year={2021}
}

2022-tpami-dcp's People

Contributors

lin-yijie avatar xlearning-scu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

2022-tpami-dcp's Issues

关于代码中的type

您好,
我想请教一个问题。
在此代码的多视图聚类版本(run_clustering_multiview.py)中,出现了config['type'] == 'CG'(CV),这里的CV和CG在处理细节上有何不同呢?如果使用的是普通的一维特征数据(非图像),该选择哪种type呢?

关于互信息中的信息熵系数

您好!我有个问题想要请教一下。
您在论文中提到,最大化互信息的损失函数中,用于调节信息熵的平衡系数lamb越高,意味着嵌入表示z中包含更丰富的信息,并且您做了相应参数实验。
我在使用您的代码运行其他数据集时,发现lamb设为0往往可以达到最好的效果,相当于删除了信息熵H这一项,这是什么原因呢?该如何解释这一现象?
期待您的解答!十分感谢!

Questions about the training period.

Hi, I have benefited greatly from your code, but I still have a small doubt:

In model.py - line 276, when the epoch reaches a certain stage (e.g. epoch>=100), the dual predictions loss function will only be involved in the gradient update.
However, this optimizer contains both auto-encoder and dual prediction parameters for training, so in the first 100 epochs, I observe that the dual prediction loss is still being computed (lines 260-265), will the parameters of the dual prediction also be updated at this training period?

关于get_mask函数中的missing_rate=0.5

您好,我想请教一下,在get_mask函数中第三行,为什么需要设置missing_rate=0.5呢?我发现这一行会使得,两视图数据和三视图数据的缺失生成使用不同的代码。

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.