LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Averaging the last N images of a live stream from a Hamamatsu Orca flash 4 V3 and displaying it

Hi everyone, 

 

I want to preface with the fact that I have no Labview experience and have been trying to teach myself most of it for the last while. 

 

What I'm trying to accomplish is the following. I have a Hamamatsu Orca Flash 4 V3 camera, which comes with a video capture library for LabView. I am trying to perform the following calculation for live image processing: <I^2> / <I>^2, where I denotes the intensity at each pixel of the image generated by the camera, and <> denotes the time average over N frames. So ultimately, I would like to display the raw live stream from the camera, and along side it, display the images generated by this averaging and normalization as the live stream acquires more images. I use the Hamamatsu video capture library to initialize and grab images from the camera, and use the IMAQ pallete to visualize the images. I have attached a VI and a screen shot of the VI (as you may not have some packages). Any help would be greatly appreciated.

Download All
0 Kudos
Message 1 of 8
(1,132 Views)

From the manual:

 

Refer to the following for examples that use this VI.

  • LabVIEW\examples\Vision\Operators\Image Averaging.vi


Then use 
imaq_muldiv To multiply it with itself (^2)

0 Kudos
Message 2 of 8
(1,094 Views)

Hi!

 

Thank you so much for the reply. I was able to use some of the samples provided by Hamamatsu and use a buffer and average the images. However, now I'm having an issue with the math. When I square the images by using the IMAQ Multiply function, I think I'm overflowing the image, and i end up with a completely white image. Do you think there's a way around it? I tried using IMage2Array, squaring it with numeric square, and then converting back, but I still get a white image and the processing gets much slower.  I've attached my HTML file for the code, and a VI.

Download All
0 Kudos
Message 3 of 8
(1,052 Views)

You probably can make the dest image a float type image

0 Kudos
Message 4 of 8
(1,041 Views)

Could you explain how I would do that in my block diagram?

0 Kudos
Message 5 of 8
(1,030 Views)

Where you create images for squares, Average of squares, Final Image, etc. with IMAQ Create.vi, change the enum Grayscale (U16) to Grayscale (SGL).

 

I don't have IMAQ installed right now, so I hope it's clear and actually works.

0 Kudos
Message 6 of 8
(1,025 Views)

Okay! I just tried that where I switched all my images to SGL, but now my images are all black (nan).

0 Kudos
Message 7 of 8
(1,018 Views)

It's probably time to wire some output errors, so you get feedback from those functions.

 

Probably the multiply doesn't allow two Grayscale (U16) image sources to be put in a Grayscale (SGL) image.

 

You might have to convert the Grayscale (U16) images first, but I couldn't find the function for that from just the manual.

0 Kudos
Message 8 of 8
(1,009 Views)