pieye / nimbus-python

nimbus python bindings
GNU General Public License v3.0
3 stars 3 forks source link

Weird values #5

Closed Olkaaaaaa12 closed 3 years ago

Olkaaaaaa12 commented 3 years ago

Hi! I have a problem with radial values from my camera. The camera is located about 2.5m above the ground and most pixels have this value but sometimes the radial value has even 12. The maximum range of camera is 5 meters according the documentation and I'm sure that nothing is more than 3 meters from the camera so do you know why I get this large value? Can I do something with it? Thanks

bjajoh commented 3 years ago

Did you check the confidence matrix? Only correctly exposed pixels include valid measurements. :) What value does it have at the pixel location with wrong distances?

Olkaaaaaa12 commented 3 years ago

I use function getImage with argument invalidAsNan=True so if pixel is not valid I get nan if I understand correctly. So this wrong distance is considered by camera as valid. I also noticed that standard deviation for central pixel has value about 0.15 when I record a video without any moving. Is it normal? And the last thing, when something is moving the radial matrix has a lot of nan value? Can it be caused by wrong exposure time? Or maybe I should change Framerate? Parameters which I use: cli.setExposureMode(NimbusClient.AUTO) cli.setAmplitude(5000) The rest is default

bjajoh commented 3 years ago

Yes, that should be fine. The quality of distance measurements is highly depended on a correct exposure. You can test different exposure settings very easily with your web browser by using "nimbus-web", just open the local Pi IP address in your browser. If you have a static environment it might be a good idea to use manual exposure. The higher the exposure the less noise. But you need to be careful to not overexpose the image. Fast movements are critical because a single image is actually combined out of 4 measurements. Reducing the exposure time in that case might help. You need to find a good trade-off that fits your use case.

Olkaaaaaa12 commented 3 years ago

Changing the exposure time helped with nan value, I'm closing the issue Thanks