Training is performed using main.py. You can specify configurations, models, and modalities via command-line arguments.
Basic Training
To train the standard CTRGCN on NTU RGB+D 120 cross-subject:
python main.py --config config/nturgbd120-cross-subject/default.yaml --work-dir work_dir/ntu120/csub/ctrgcn --device 0
Training with different modalities (Bone or Velocity)
For NTU datasets, use --train_feeder_args and --test_feeder_args to set bone=True or vel=True.
python main.py --config config/nturgbd120-cross-subject/default.yaml --train_feeder_args bone=True --test_feeder_args bone=True --work-dir work_dir/ntu120/csub/ctrgcn_bone --device 0
For NW-UCLA, modify data_path in the feeder args to bone, motion, or bone motion:
python main.py --config config/ucla/default.yaml --work-dir work_dir/ucla/ctrgcn_xxx --device 0
Training a custom model
Place your model file your_model.py in the ./model directory and reference it using the --model flag with the format model.your_model.Model.
python main.py --config config/nturgbd120-cross-subject/default.yaml --model model.your_model.Model --work-dir work_dir/ntu120/csub/your_model --device 0
# Example: training CTRGCN on NTU RGB+D 120 cross subject under bone modality
python main.py --config config/nturgbd120-cross-subject/default.yaml --train_feeder_args bone=True --test_feeder_args bone=True --work-dir work_dir/ntu120/csub/ctrgcn_bone --device 0