01-09-2010 08:14 AM
Hello everyone,
I have an application that requires a centroid calculation is performed on an image. Vision Assistant 2009 provides a convenient way to perform this task.
My problem is the camera requires a NUC to be performed and the software package that comes with the camera stores in the NUC information in three files on the computer. Any other program that looks at the camera output does not have this correction applied.
How do I correct the gain and add the offset? Also, how do I do a bad pixel mapping?
Does anyone have any sample scripts to perform this task?
Thanks,
Ed
01-11-2010 09:53 AM
Just a guess here, but is this a radiometric camera from FLIR? Using RDAC as its capturing software? You don't have to answer these questions, just curious.
A NUC is fairly easy to apply, once you have read the file from disk. There is a gain image and an offset image, with the offset being added, then the gain multiplied. Bad pixels are fairly easy to apply as well, depending on how you want to apply them. You could do a simple replace algorithm, which would replace the bad pixel with the pixel above it, or some sort of averaging algorithm could be used as well. Both methods have to deal with the case where your pixel is located on the outer edge of the image.
As it stands, you'll need to get the NUC (and the Bad Pixel) file format before you can get much further. Once you have them and can read in the files you should be able to apply them using standard IMAQ routines like IMAQ Add, IMAQ Multiply, and IMAQ Get/Set Pixel Value. I don't have IMAQ on the computer I'm working at right now, so the function names may not be spot on, but there is something like these functions in the standard IMAQ math and pixel routines.
01-11-2010 11:28 AM
This is a FLIR radiometric camera and I'm using RTools.
Any ideas on how to convert the file so Vision Assistant can use them? I can read the files, but don't know what type of file conversion I will have to do.
Thanks for the Help.
01-11-2010 01:06 PM
Sorry I didn't see that you were using Vision Assistant. I'm not totally familiar with that product, but if I remember correctly you can make a custom LabVIEW step that might be able to do what you want, or export your code to some version of LabVIEW to work with your data there. I've created a snapshot of the basic idea of what you will need to do with the gain, bad pixel, and offset files once they are read into LabVIEW. I've attached it to this post.