neural-motifs icon indicating copy to clipboard operation
neural-motifs copied to clipboard

training relationships

Open Ballester opened this issue 6 years ago • 2 comments

Hello,

I got an issue while trying to train a relationship model. I can reproduce the results in the detection training (pretrain_detector), but fail to induce a good model when doing relationship detection (train_rels).

The final model always predicts the same class (0). I was wondering whether I am doing something wrong or if you also encountered the same problem.

Training with standard config: python3 models/train_rels.py -m predcls -model motifnet -nl_obj 0 -nl_edge 0 -b 6 -clip 5 -p 100 -pooling_dim 4096 -lr 1e-3 -ngpu 1 -ckpt /A/ballester/neural-motifs/checkpoints/vg-faster-rcnn.tar -save_dir /A/ballester/neural-motifs/checkpoints/rels_vgg -nepoch 50 -use_bias -hidden_dim 512

Ballester avatar Mar 29 '19 14:03 Ballester

hey! sorry for the delay in response. I think this trains a baseline model, rather than motifnet. Did you try using this command?

    python models/train_rels.py -m sgcls -model motifnet -order leftright -nl_obj 2 -nl_edge 4 -b 6 -clip 5 \
        -p 100 -hidden_dim 512 -pooling_dim 4096 -lr 1e-3 -ngpu 1 -ckpt checkpoints/vgdet/vg-24.tar \
-save_dir checkpoints/motifnet2 -nepoch 50 -use_bias

rowanz avatar Apr 11 '19 18:04 rowanz

Thank you for the response. Yeah, actually it was the baseline I was trying to reproduce in an attempt to get results on object relationship without using the LSTM. Is that correct or should I use another command?

Ballester avatar Apr 11 '19 18:04 Ballester