yrcong / RelTR

RelTR: Relation Transformer for Scene Graph Generation: https://arxiv.org/abs/2201.11460v2
229 stars 45 forks source link

Error during training in bbox.pyx : ValueError: Buffer dtype mismatch, expected 'DTYPE_t' but got 'double' #47

Closed aelayouch closed 4 months ago

aelayouch commented 4 months ago

Hi, Thank you for your work ! I try to train the model on a customized dataset, but after the first epoch, I have the following error at the lines of sg_eval.py : sub_iou = bbox_overlaps(gt_box[None, :4], boxes[:, :4])[0] obj_iou = bbox_overlaps(gt_box[None, 4:], boxes[:, 4:])[0]

File "bbox.pyx", line 17, in bbox.bbox_overlaps ValueError: Buffer dtype mismatch, expected 'DTYPE_t' but got 'double'

Have you ever had this issue ?

aelayouch commented 4 months ago

Solved => changing "float" by "double" in bbox.pyx ctypedef double DTYPE_t instead of ctypedef float DTYPE_t