Home

Awesome

Skeleton-Contrastive 3D Action Representation Learning

arch

This repository contains the implementation of our ACM MultiMedia 2021 paper:

Link:

[PDF] [Arxiv]

Requirements

 conda create -n  skeleton_contrast python=3.7 anaconda
 conda install pytorch==1.2.0 torchvision==0.4.0 -c pytorch
 pip install tensorboard

Data prepreprocessing instructions

cd data_gen
python ntu_gendata.py

Pretrain Instruction

CUDA_VISIBLE_DEVICES=0,1,2,3 python  main_moco_inter_skeleton.py \
  --lr 0.01 \
  --batch-size 64 \
  --mlp --moco-t 0.07   --moco-k 16384  --checkpoint-path ./checkpoints/ntu_60_cross_view/interskeleton_seq_based_graph_based  --schedule 351  --epochs 451  --pre-dataset ntu60 --skeleton-representation seq-based_and_graph-based --protocol cross_view

Downstream Instruction

CUDA_VISIBLE_DEVICES=0,1,2,3 python action_classification.py \
  --lr 0.1 \
  --batch-size 64 \
 --pretrained  ./checkpoints/ntu_60_cross_view/interskeleton_seq_based_graph_based/checkpoint_0450.pth.tar \
  --finetune-dataset ntu60 --protocol cross_view --pretrain-skeleton-representation seq-based_and_graph-based  --finetune-skeleton-representation seq-based
 CUDA_VISIBLE_DEVICES=0,1,2,3 python action_retrieval.py \
  --lr 0.1 \
  --batch-size 64 \
  --knn-neighbours 1 \
  --pretrained  ./checkpoints/ntu_60_cross_view/interskeleton_seq_based_graph_based/checkpoint_0450.pth.tar \
 --finetune-dataset ntu60 --protocol cross_view --pretrain-skeleton-representation seq-based_and_graph-based  --finetune-skeleton-representation seq-based

Pretrained Models

Results

Citation

If you use our work or code, kindly consider citing our paper:

@InProceedings{fmthoker_acmmm,
  author    = {Fida Mohammad Thoker, Hazel Doughty and Cees Snoek},
  title     = {Skeleton-Contrastive 3D Action Representation Learning},
  booktitle = {in Proceedings of the 29th ACM International Conference on Multimedia,(ACM MM), 2021},
  year      = {2021},
}