From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Acquire sequences of image

Solved!
Go to solution

Hello,

 

I am trying to capture a series of images at a set frame rate and for a preset duration. I attach the script that I'm using. The problem is that if I set a number of images greater than 300 I get this error: "Error -1074396159 Not enough memory for requested operation". My computer is not full and the memory is not a problem. 

I'm using the 2020 version of labview with an USB camera.

 

Thanks everyone for the help.

0 Kudos
Message 1 of 7
(1,209 Views)

Nothing is attached.  Make sure it is an actual VI.  You mentioned "script" but LabVIEW doesn't have scripts.

0 Kudos
Message 2 of 7
(1,195 Views)

Sorry I don't know why it isn't attached to the previous message.

0 Kudos
Message 3 of 7
(1,184 Views)

How much memory does each image take?  300 is a lot of images.  What exactly to you mean by "my computer is not full"?  That sounds like you are talking about hard drive space which is not important in this case.  It is about memory.  A 4 MB image will take 1.2 GB when you multiply by 300.

0 Kudos
Message 4 of 7
(1,177 Views)

I think the size of each image is about 2 MB, I'm using a PC with 8 GB of Ram and 512 of hard disk. Do you think the problem is due to the weight of too many images?

0 Kudos
Message 5 of 7
(1,167 Views)
Solution
Accepted by topic author Raffaele96

Despite being 8 GB, you'll never get to use that much due to the OS and the other programs.  I expect you can start seeing out of memory areas when you program approaches about 2GB, from my experience with programs that eat up memory.

 

It's possible that memory usage doubles as it combines the individual images into a larger video stream.  Also, you may not be running out of memory, but running out of contiguous memory.  It's possible that the combine sequence needs to be stored in one continuous chunk of memory, but with fragmentation, the remaining chunks of free memory aren't large enough.

 

I've barely touched Imaq stuff, so I don't know the underlying details of how it handles memory.

Message 6 of 7
(1,143 Views)

thank you so much for your help and time spent answering me.

0 Kudos
Message 7 of 7
(1,104 Views)