classes = outputs['instances'].pred_classes.to('cpu') boxes = outputs['instances'].pred_boxes.to('cpu')
frame_df = pd.DataFrame({'Classes': classes, 'Boxes': boxes})
df = pd.concat([df, frame_df], ignore_index=True)
frame = cv2.cvtColor(frame, cv2.COLOR_RGB2BGR)
I am trying to save the classes and box parameters of the detected objects in a video but, the result only shows 0,0... in the classes section of my csv file. However, the box parameter is being shown properly.