zhou13 / neurvps

Neural Vanishing Point Scanning via Conic Convolution
MIT License
178 stars 22 forks source link

offset calculation in ConicConv #23

Closed gukai330 closed 2 years ago

gukai330 commented 2 years ago

thank you for your inspiring work!

I have one question regarding the offset calculation in the conic convolution module

https://github.com/zhou13/neurvps/blob/4eec4ecd98eb7e5dddb82d1c4141d63087c74cf1/neurvps/models/conic.py#L44-L48

As I understand it, the offset tensor saves a matrix of pixel offsets of rotated convolutional kernels (pointing to the VP)

\ I think this line already did the job https://github.com/zhou13/neurvps/blob/4eec4ecd98eb7e5dddb82d1c4141d63087c74cf1/neurvps/models/conic.py#L46 \ what do these lines do? https://github.com/zhou13/neurvps/blob/4eec4ecd98eb7e5dddb82d1c4141d63087c74cf1/neurvps/models/conic.py#L47-L48

I tried to visualize the kernels with offset with/ without 47~48 lines.

w/ (this add some weird rotation to the kernel, and the size become different) w w/o wo

does this have anything to do with the CUDA part here? https://github.com/zhou13/neurvps/blob/4eec4ecd98eb7e5dddb82d1c4141d63087c74cf1/neurvps/models/cpp/deform_im2col_cuda.cuh#L173-L174 also, the dilation here is a bit weird.

thank you again in advance!

zhou13 commented 2 years ago

If I recall correctly, this is related to the default offset from deformable conv. You need to "offset" the default offset.