Nightmare-n / GD-MAE

GD-MAE: Generative Decoder for MAE Pre-training on LiDAR Point Clouds (CVPR 2023)
Apache License 2.0
114 stars 6 forks source link

about the CLASS #14

Open Karkers opened 1 year ago

Karkers commented 1 year ago

12

我添加了剩余的两个类别,并且添加了anchor,second mini无法运行,显示以下错误。(这个anchor我是从gdmae的模型里复制过来的)

Traceback (most recent call last): | 0/928 [00:00<?, ?it/s] File "train.py", line 205, in main() File "train.py", line 174, in main merge_all_iters_to_one_epoch=args.merge_all_iters_to_one_epoch File "/home/karker/PROJ/GD-MAE/tools/train_utils/train_utils.py", line 120, in train_model dataloader_iter=dataloader_iter File "/home/karker/PROJ/GD-MAE/tools/train_utils/train_utils.py", line 46, in train_one_epoch loss, tb_dict, disp_dict = model_func(model, batch, global_step=accumulated_iter) File "../pcdet/models/init.py", line 31, in model_func ret_dict, tb_dict, disp_dict = model(batch_dict) File "/home/karker/anaconda3/envs/gd-mae/lib/python3.7/site-packages/torch/nn/modules/module.py", line 1102, in _call_impl return forward_call(*input, kwargs) File "/home/karker/anaconda3/envs/gd-mae/lib/python3.7/site-packages/torch/nn/parallel/distributed.py", line 886, in forward output = self.module(*inputs[0], *kwargs[0]) File "/home/karker/anaconda3/envs/gd-mae/lib/python3.7/site-packages/torch/nn/modules/module.py", line 1102, in _call_impl return forward_call(input, kwargs) File "../pcdet/models/detectors/second_net.py", line 14, in forward loss, tb_dict, disp_dict = self.get_training_loss() File "../pcdet/models/detectors/second_net.py", line 27, in get_training_loss loss_rpn, tb_dict = self.dense_head.get_loss() File "../pcdet/models/dense_heads/anchor_head_template.py", line 217, in get_loss cls_loss, tb_dict = self.get_cls_layer_loss(tb_dict) File "../pcdet/models/dense_heads/anchor_head_template.py", line 123, in get_cls_layer_loss cls_loss_src = self.cls_loss_func(cls_preds, one_hot_targets, weights=cls_weights) # [N, M] File "/home/karker/anaconda3/envs/gd-mae/lib/python3.7/site-packages/torch/nn/modules/module.py", line 1102, in _call_impl return forward_call(*input, *kwargs) File "../pcdet/utils/loss_utils.py", line 60, in forward pt = target (1.0 - pred_sigmoid) + (1.0 - target) * pred_sigmoid RuntimeError: The size of tensor a (13516800) must match the size of tensor b (211200) at non-singleton dimension 1