Sequence acquisition sometimes stops unexpectedly

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Sequence acquisition sometimes stops unexpectedly

Daniel Dickinson
Hi all,

I am using a derivative of the code here https://micro-manager.org/w/images/4/43/BurstExample.bsh to try to run a series of sequence acquisitions in which I acquire 500 frames (at 20 FPS), move to another stage position, repeat etc.  For the most part this works fine, but periodically an acquisition will stop after 464 frames (it's always 464 frames).  There is no error message of any kind, the acquisition just stops.  This only happens about 1 in 5 acquisitions; the rest of the time, all 500 frames are acquired successfully. I initially suspected some kind of a memory issue since it always stops in the same place, but increasing the sequence buffer size had no effect on the behavior (or the location of the stop).

Has anyone else encountered this issue?  Any suggestions for how to troubleshoot?

Thanks,
Dan



_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: Sequence acquisition sometimes stops unexpectedly

Daniel Dickinson
I was able to solve this issue by increasing the memory available to ImageJ (under Edit>Options>Memory&Threads).  So it was a memory issue after all, just not an issue with the sequence buffer.  In the course of troubleshooting, a couple of more-specific questions came up:
  • The weirdest thing about this behavior is that when I click on the ImageJ status bar, it never shows that the amount of memory used exceeds 50-60 MB, which is only ~1% of the total available.  Yet in Task Manager I can see that the memory used increases over the course of each acquisition.  If the memory usage isn't counting against ImageJ's allocation, then where is the image being stored?  Or is this just an issue of ImageJ not displaying its memory usage properly?
  • The issue with the acquisition stopping seems to only occur after 2-3 sequences have been acquired, suggesting that memory usage is building up until it exceeds the memory available.  When each acquisition is done, I am saving the data to disk and then calling gui.closeAcquisitionWindow() followed by gui.closeAllAcquisitions().  Do these commands also clear the acquired image from memory, freeing space for the next acquisition?  If not, what command do I issue to do so?
Happy to share my complete code if it would help.

Thanks,
Dan


From: Daniel Dickinson <[hidden email]>
Sent: Tuesday, February 12, 2019 4:29 PM
To: Micro-Manager General
Subject: [micro-manager-general] Sequence acquisition sometimes stops unexpectedly
 
Hi all,

I am using a derivative of the code here https://micro-manager.org/w/images/4/43/BurstExample.bsh to try to run a series of sequence acquisitions in which I acquire 500 frames (at 20 FPS), move to another stage position, repeat etc.  For the most part this works fine, but periodically an acquisition will stop after 464 frames (it's always 464 frames).  There is no error message of any kind, the acquisition just stops.  This only happens about 1 in 5 acquisitions; the rest of the time, all 500 frames are acquired successfully. I initially suspected some kind of a memory issue since it always stops in the same place, but increasing the sequence buffer size had no effect on the behavior (or the location of the stop).

Has anyone else encountered this issue?  Any suggestions for how to troubleshoot?

Thanks,
Dan



_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general