Closed wojtat closed 5 months ago
I have the same problem with you, I fix "pos_idx = (batched_bbox>=0)&(batched)bbox_labels<args.nclasses)" in train.py to "pos_idx = (batched_bbox>=0)&(batched)bbox_labels<args.nclasses+1)" to slove this problem.
This is because forward() in pointpillars.py will always pass a 3-row assigner matrix to anchor_target(). A quick fix is to select only the first nclasses assigners to proceed the program.
if mode == 'train':
anchor_target_dict = anchor_target(batched_anchors=batched_anchors,
batched_gt_bboxes=batched_gt_bboxes,
batched_gt_labels=batched_gt_labels,
assigners=self.assigners[:self.nclasses],
nclasses=self.nclasses)
Hi, I'm trying to run
train.py --nclasses 1
, but it results in anIndexError
:It works fine with the default value of
nclasses
, but giving1
gives this error. Can I ask for some help with fixing this please?