krrish94 / nerf-pytorch

A PyTorch re-implementation of Neural Radiance Fields
Other
872 stars 123 forks source link

A question regarding the variable ray_directions #27

Open OshriHalimi opened 3 years ago

OshriHalimi commented 3 years ago

Based on the documentation here: https://github.com/krrish94/nerf-pytorch/blob/a14357da6cada433d28bf11a45c7bcaace76c06e/nerf/nerf_helpers.py#L85 I would expect ray_directions to contain unit vectors. However, numerically looking into the values, this is not the case - the values are close to 1 but have a large variation around the exact value (around 10%-20%).

Is this a bug? If not, what is the meaning of the vector magnitude?

Thanks!

airalcorn2 commented 2 years ago

ray_directions is eventually normalized in run_one_iter_of_nerf.