[ICCV 2021] A new codebase containing various methods for Group Activity Recognition. Paper title: Spatio-Temporal Dynamic Inference Network for Group Activity Recognition.
MIT License
53
stars
15
forks
source link
ValueError: cannot reshape array of size 90 into shape (12) #24
When I follow your steps and run the python scripts/train_volleyball_stage1.py command, there is an error ValueError: cannot reshape array of size 90 into shape (12).
When I navigated to line 266 of the volleyball.py file actions = np.hstack(actions).reshape([-1, self.num_boxes]), I found that there was a piece of code at lines 259 to 261 when the array was stacked earlier. :
if len(boxes[-1]) ! = self.num_boxes:
boxes[-1] = np.vstack([boxes[-1], boxes[-1][:self.num_boxes-len(boxes[-1])]])
actions[-1] = actions[-1] + actions[-1][:self.num_boxes-len(actions[-1])].
When I printed, I found that the length of len(boxes[-1]) was equal to the length of self.num_boxes, so the inequality sign (!=) caused this code to not work. When I put The program can run when != is changed to ==. But the accuracy of the first stage is not up to the accuracy in your code. Does this issue have an impact on the results?Can you provide the checkpoints of your first stage? Thanks
When I follow your steps and run the python scripts/train_volleyball_stage1.py command, there is an error ValueError: cannot reshape array of size 90 into shape (12). When I navigated to line 266 of the volleyball.py file actions = np.hstack(actions).reshape([-1, self.num_boxes]), I found that there was a piece of code at lines 259 to 261 when the array was stacked earlier. : if len(boxes[-1]) ! = self.num_boxes: boxes[-1] = np.vstack([boxes[-1], boxes[-1][:self.num_boxes-len(boxes[-1])]]) actions[-1] = actions[-1] + actions[-1][:self.num_boxes-len(actions[-1])]. When I printed, I found that the length of len(boxes[-1]) was equal to the length of self.num_boxes, so the inequality sign (!=) caused this code to not work. When I put The program can run when != is changed to ==. But the accuracy of the first stage is not up to the accuracy in your code. Does this issue have an impact on the results?Can you provide the checkpoints of your first stage? Thanks