From 5cb59b35d4cbd381d58afc9115be5e87a0071e0f Mon Sep 17 00:00:00 2001 From: Stephan Saalfeld Date: Tue, 2 Aug 2011 16:18:57 +0200 Subject: [PATCH] flush image cache memory before doing a montage TODO this is not a proper solution for the problem, make montage acquire the estimated amount of memory that it needs --- mpicbg/trakem2/align/ElasticMontage.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mpicbg/trakem2/align/ElasticMontage.java b/mpicbg/trakem2/align/ElasticMontage.java index 6b67e007..dc860986 100644 --- a/mpicbg/trakem2/align/ElasticMontage.java +++ b/mpicbg/trakem2/align/ElasticMontage.java @@ -327,7 +327,10 @@ public class ElasticMontage extends AbstractElasticAlignment final Param p, final List< Patch > patches, final List< Patch > fixedPatches ) throws Exception - { + { + /* free memory */ + patches.get( 0 ).getProject().getLoader().releaseAll(); + /* create tiles and models for all patches */ final List< AbstractAffineTile2D< ? > > tiles = new ArrayList< AbstractAffineTile2D< ? > >(); final List< AbstractAffineTile2D< ? > > fixedTiles = new ArrayList< AbstractAffineTile2D< ? > > (); -- 2.11.4.GIT