sunset1995 / HorizonNet

Pytorch implementation of HorizonNet: Learning Room Layout with 1D Representation and Pano Stretch Data Augmentation.
https://sunset1995.github.io/HorizonNet/
MIT License
324 stars 88 forks source link

about `np_coorx2u` and `np_coory2v ` function in `post_proc.py` #31

Closed zhigangjiang closed 3 years ago

zhigangjiang commented 3 years ago

hi, sunset I am very interested in your work then I have an issue about np_coorx2u and np_coory2v function in post_proc.py

def np_coorx2u(coorx, coorW=1024):
    return ((coorx + 0.5) / coorW - 0.5) * 2 * PI

def np_coory2v(coory, coorH=512):
    return -((coory + 0.5) / coorH - 0.5) * PI

I think coorx / coorW or coory / coorH already got rate , why need +0.5?