micasense / imageprocessing

MicaSense RedEdge and Altum image processing tutorials
https://www.micasense.com
MIT License
247 stars 147 forks source link

Bug encountered with panel_albedo reporting different reflectance values #196

Open pakhuiying opened 1 year ago

pakhuiying commented 1 year ago

Different panel_albedo was reported for the same CRP panel on separate surveys, which should not happen since the CRP panels are pre-calibrated. We are using the

Please see the example images attached here

Code for reproducing the error:

import glob import micasense.capture as capture

panel_fp = r"panel_issue/example_1" basename = panel_fp[:-6] fn = glob.glob('{}_*.tif'.format(basename))

output >>> [0.48112499999999997, 0.4801333333333333, 0.4788733333333333, 0.4768433333333333, 0.4783016666666666, 0.4814866666666666, 0.48047166666666663, 0.4790833333333333, 0.47844166666666665, 0.4780333333333333]

panel_fp = r"panel_issue/example_2" basename = panel_fp[:-6] fn = glob.glob('{}_*.tif'.format(basename))

output >>> [0.491, 0.4898666666666667, 0.4884266666666667, 0.4861066666666667, 0.48777333333333334, 0.49141333333333337, 0.4902533333333333, 0.4886666666666667, 0.48793333333333333, 0.48746666666666666]

Panel albedo values differed by around 1%, which is a significant issue for us. I doubt that it is a floating point precision issue. Please advice, thank you!

barreto91 commented 1 year ago

I have the same problem! It seems that the panel boundaries are being wrongly recognized. Has anyone managed to solve this problem?

MicrosoftTeams-image (1)

adamjson64 commented 11 months ago

I've been doing some work on adding support for the RP06 panels to our application and this issue caught my attention. It looks like the panel captured in example 1 and example 2 is different based on the QR serial number printed at the top of the board, which seems to be the most likely explanation. If you inspect the minimum and maximum reflectance that are encoded in the QR code you will find they are slightly different:

Example 1 Min WL: 400.0 Min RF: 0.482 Max WL: 1000.0 Max RF: 0.475

Example 2 Min WL: 400.0 Min RF: 0.492 Max WL: 1000.0 Max RF: 0.484

Perhaps the lambertian material is slightly different hence the different range of values provided by MicaSense?

In our case, the values encoded in the QR code are far more suspicious as the min and max reflectance values are exactly the same, which I've reached out to MicaSense about:

400.0 0.517 1000.0 0.517

I am simply printing the values to the console that are found in panel::reflectance_from_panel_serial

I hope this helps.