Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Strange deviations of the intensities with IMAQ Flat Field Correction VI

Observed strange behavior (intensities deviations) with NI IMAQ Flat Field Correction VI.

As stated here the corrected image computed as:

eq_flat_field_correction

Let proof this with simple VI:

snippet.png

First test just with constants: The Image with 2000 grays, Flat Field - 1000 grays and Dark Field 100 grays only. So far so good:

Screenshot 2023-06-19 18.39.51.png

Now now I have "underresponding pixel", which deliver the only half intensity in Flat Field in my test image:

Screenshot 2023-06-19 18.41.07.png

As you can see, the median was not changed, the factor for this pixel increased to 2,25 and I have more or less flat result around 2000 grays, but NI's result is only the half. Look like kind of "normalization" running behind the scenes.

Now a little bit magic. I will increment intensity of the single pixel in Gain image from 1000 to 1001, keep other unchanged and then the results are the same (more or less):

Screenshot 2023-06-19 18.42.17.png

In general the same with Dark Field Image, I can get the values well below the expected, or significantly above. 

May be issue with normalization, may be rounding, may be with Median, but anyway the practical results is different from mathematical theory.

Looks like an issue for me.

 

0 Kudos
Message 1 of 2
(715 Views)

Last weekend just wrote own implementation (LabVIEW 2023Q1 + CVI 2020), which at least matched "reference" computation and roughly 3+ times faster than original NI (because SIMD optimized using intrinsics).

Errors handling is minimal, feel free to modify, or use "as is" at own risk.

Andrey.

 

Message 2 of 2
(636 Views)