pieye / nimbus-python

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

Unable to access valid points value #7

Closed 9and3 closed 2 years ago

9and3 commented 2 years ago

Hello there! I just put our hands on one of your nimbus camera, really amazing piece of sensor! I am following your readme file in the main page and I would like to get the valid points in order to trim the rest out of the point cloud. So I am doing:

header, (ampl, radial, x, y, z, conf) = cli.getImage(invalidAsNan=True)
numUnderExposured = len(conf[conf==NimbusClient.ConfUnderExposured])
numOverExposured = len(conf[conf==NimbusClient.ConfOverExposured])
numAsymmetric = len(conf[conf==NimbusClient.ConfAsymmetric])
numValid = len(conf[conf==NimbusClient.ConfValid])

But i recive this error message saying that "module 'nimbusPython.NimbusClient' has no attribute 'ConfValid' " I am on Ubuntu 20.04.3 LTS in case. Thank you for your help!

bjajoh commented 2 years ago

Hi @9and3! Glad that you got one! Are you using our raspberry os images? Can you access the nimbus over the browser and see the images?

You're probably right, please replace "ConfValid" with "ConfLong" and try again.

9and3 commented 2 years ago

Hello @bjajoh, thanks for the prompt reply! Yes I did install the your image on the raspberry pi and everything works fine through the browser service, I can see the point cloud and all. Ok for the "ConfValid", yet I see there is a "ConfLong" and "ConfShort", what is the difference between the two? thanks!

bjajoh commented 2 years ago

We added a multi exposure to the camera. It takes a long and short exposure for every image in order to increase the dynamic range. Therefore a valid pixel can either be short or long exposed. The union of both equals the old valid measure. Let me know if you have any other questions!

9and3 commented 2 years ago

Amazing! Thanks for the answer. Actually I would have a couple of questions about how I can use the Nimbus in a particular application I am working on (research lab in timber digital fabrication in Switzerland). It would be great if I could send you a private message about that! In any case thanks for the quick reply on this one!