CornerNet icon indicating copy to clipboard operation
CornerNet copied to clipboard

ERROR: Dimension out of range (expected to be in range of [-2, 1], but got 2)

Open Hao-Gong opened this issue 5 years ago • 4 comments

not only occurs in Cornernet but also in Cornernet-Lite. I cannot know why, please help me, thx!

"CornerNet/models/py_utils/kp_utils.py", line 197, in _ae_loss dist = tag_mean.unsqueeze(1) - tag_mean.unsqueeze(2) RuntimeError: Dimension out of range (expected to be in range of [-2, 1], but got 2)

Hao-Gong avatar Sep 13 '19 02:09 Hao-Gong

FIXED cause my GPU MEM is small that i change the chunk size to 1 and batch to 1.

Hao-Gong avatar Sep 13 '19 05:09 Hao-Gong

FIXED cause my GPU MEM is small that i change the chunk size to 1 and batch to 1.

Have you solved your problem? I meet the same problem that the Gpu memory is small. (QAQ)

chong-zheng avatar Mar 30 '20 13:03 chong-zheng

@diamour @chong-zheng i use CenterNet and has the same error, i had been read the issues in CenterNet,CornerNet and CornerNet-Lite, but i still dont see the answer. cuda10, torch1.0, torchvision0.2.1, i used env from CornerNet-Lite, batch-size = 1;one gpu-gtx1060ti ———————————————————————— RuntimeError: Dimension out of range (expected to be in range of [-2, 1], but got 2)

Glutton-zh avatar Apr 01 '20 07:04 Glutton-zh

change chunk size to 2 and batch to 2, this works for me.

bigpo avatar Apr 02 '20 07:04 bigpo