samiragarwala / PlaneFormers

[ECCV 2022] PlaneFormers: From Sparse View Planes to 3D Reconstruction
https://samiragarwala.github.io/PlaneFormers/
MIT License
84 stars 4 forks source link

Scannet image Error: cdist only supports at least 2D tensors, X2 got: 1D #8

Open laliwang opened 1 week ago

laliwang commented 1 week ago

I also meet this error when I try to reproduce your code on several images from scannet_v2. Could you please provide some advice on how to handle this? My emb_i and emb_j shape output like follows: 0 torch.Size([5, 128]) torch.Size([5, 128]) 1 torch.Size([5, 128]) torch.Size([128])

laliwang commented 1 week ago

I figure out the reason that the first dim of emb_i/j maybe presents the detected plane number in the image. Thus, I just make an additional judgement whether the dim equals to 1 then unsqueeze it for normal running. However, I have no idea if only one plane detected would cause performance degration.