Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Extract ROI and perform FFT

Hi,

I'm using a Basler acA2000 340kc controled through a PCIe 1473R FPGA. I am obtaining succesful images. I'd like now to be able to select n ROI from the image and show the FFT of this ROI.

I have then two questions, as I have no previous experince in doing this.

1) How do I extract the ROI from the image? I'd like to select a ROI from the image and display it.

2) How do I perform the FFT from the selected ROI?

Thanks a lot for your help,
Rafa

0 Kudos
Message 1 of 18
(6,655 Views)

Hello,

 

you can use ROI property node to extract the subimage and perfrom FFT on the subimage.

 

A basic example:

 

Example_VI_BD.png

 

Just remember that using the IMAQ FFT, the high frequencies are in the center (you can flip them if it suits you better).

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
Message 2 of 18
(6,591 Views)

Thanks a lot! That seems really useful.

It seems though that some VI in that code require NI VIsion Development Module, is this right?

Is this module separated from the LabView basic module. We have some VIs related with the ROI, but not all of them.

 

Is it essential to have this module in order to do what we want to do??
Thanks for your help. 

0 Kudos
Message 3 of 18
(6,576 Views)

Hello,

 

sorry I assumed you've got NI Vision. This would also work:

 

Example_VI_BD.png

 

You can extract the ROI by using "array subset", prior to FFT.

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
Message 4 of 18
(6,565 Views)

Thanks a lot.

How is it called the last IMAQ VI? It seems to convert the complex number to image, but I cannot find it, and obviously the simple array to image does not work.

Thanks a lot,

Rafa

0 Kudos
Message 5 of 18
(6,549 Views)

I found that it is array to complex image, but it turns out that I do not have such VI, I guess it's also in the image development module. Is that true?

http://zone.ni.com/reference/en-XX/help/370281M-01/imaqvision/imaq_arraytocompleximage/

 

Thanks for your help,
Rafa

0 Kudos
Message 6 of 18
(6,548 Views)

Hello,

yes you are right. Concentrate on the part inside the rectangle (the actual FFT) and ignore Vision vi's. They were just for visual verification. You don't need those if you don't have Vision.

 

How is the image data passed? How do you display the image?


Best regards,
K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
Message 7 of 18
(6,539 Views)

Hi,

I have downloaded a trial version of the moduel in order to check if I'm interested in it.

I'm acquiring images through a Basler camera. I implemented your code for the FFT but no image is displayed (although a frame appears). I'm placing the code in the loop where the image is acquired. By probing the wires, I see that the image to array converter seems not to convert anything.

Any idea on this point?
thanks a lot

0 Kudos
Message 8 of 18
(6,533 Views)

Hello,

 

can you post a screenshot of your code? Only the relevant part.

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
Message 9 of 18
(6,505 Views)

Hey, thanks for your help.

I send you the part where the image is initiated and the loops that acquire the image. My frame grabber is an FPGA so I'm basically using the example 10Tap 8 bit Camera with DRAM.

tHANKS

0 Kudos
Message 10 of 18
(6,494 Views)