Error when plotting priors and posteriors
Posted: Mon Mar 25, 2013 4:51 pm
Dear Dynare developers,
I have a problem when running a Bayesian estimation (300000 mh replications, 2 mh_blocks). In the command window the posterior mean and covariance are computed, I can see the estimation results, but when it should plot the figures of the priors and posteriors I get the following error:
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent._paintImmediately(Unknown Source)
at javax.swing.JComponent.paintImmediately(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)??? Operation terminated by user during ==> PlotPosteriorDistributions at 157
In ==> dynare_estimation_1 at 891
oo_ = PlotPosteriorDistributions(estim_params_, M_, options_, bayestopt_, oo_);
In ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});
In ==> umw_rob1955 at 480
dynare_estimation(var_list_);
In ==> dynare at 120
evalin('base',fname) ;
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.lang.Integer.toString(Unknown Source)
at com.mathworks.mwswing.desk.DTNestedLocation.toXML(DTNestedLocation.java:311)
at com.mathworks.mwswing.desk.DTClient.toXML(DTClient.java:1746)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:4639)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:4557)
at com.mathworks.mwswing.desk.Desktop$38.call(Desktop.java:3665)
at com.mathworks.mwswing.desk.Desktop$38.call(Desktop.java:3656)
at com.mathworks.mwswing.desk.Desktop.deferredCall(Desktop.java:7055)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:3655)
at com.mathworks.mwswing.desk.DTLayoutSaveManager.performSave(DTLayoutSaveManager.java:127)
at com.mathworks.mwswing.desk.DTLayoutSaveManager.access$500(DTLayoutSaveManager.java:18)
at com.mathworks.mwswing.desk.DTLayoutSaveManager$1.actionPerformed(DTLayoutSaveManager.java:47)
at javax.swing.Timer.fireActionPerformed(Unknown Source)
at javax.swing.Timer$DoPostEvent.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
And I cannot see all the rest, such as bayesian irf etc. I tried with 3000 replications and it works. How can I fix this problem and run at least 250000 mh replications for 2 blocks?
Thanks in advance for your help.
Lara
PS: I am using dynare version 4.3.1 (it also happened in version 4.2.4). The last time I was running 300000 mh replications for 2 blocks was a month ago and it was working.
I have a problem when running a Bayesian estimation (300000 mh replications, 2 mh_blocks). In the command window the posterior mean and covariance are computed, I can see the estimation results, but when it should plot the figures of the priors and posteriors I get the following error:
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent._paintImmediately(Unknown Source)
at javax.swing.JComponent.paintImmediately(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.<init>(Unknown Source)
at java.awt.image.Raster.createPackedRaster(Unknown Source)
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(Unknown Source)
at sun.awt.image.SunVolatileImage.getBackupImage(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.getBackupSurface(Unknown Source)
at sun.awt.image.VolatileSurfaceManager.initialize(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.image.SunVolatileImage.<init>(Unknown Source)
at sun.awt.windows.WComponentPeer.createVolatileImage(Unknown Source)
at java.awt.Component.createVolatileImage(Unknown Source)
at java.awt.Component$BltBufferStrategy.createBackBuffers(Unknown Source)
at java.awt.Component$BltBufferStrategy.<init>(Unknown Source)
at java.awt.Component$BltSubRegionBufferStrategy.<init>(Unknown Source)
at java.awt.Component.createBufferStrategy(Unknown Source)
at java.awt.Window.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.createBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager$BufferInfo.getBufferStrategy(Unknown Source)
at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)??? Operation terminated by user during ==> PlotPosteriorDistributions at 157
In ==> dynare_estimation_1 at 891
oo_ = PlotPosteriorDistributions(estim_params_, M_, options_, bayestopt_, oo_);
In ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});
In ==> umw_rob1955 at 480
dynare_estimation(var_list_);
In ==> dynare at 120
evalin('base',fname) ;
at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
at java.lang.Integer.toString(Unknown Source)
at com.mathworks.mwswing.desk.DTNestedLocation.toXML(DTNestedLocation.java:311)
at com.mathworks.mwswing.desk.DTClient.toXML(DTClient.java:1746)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:4639)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:4557)
at com.mathworks.mwswing.desk.Desktop$38.call(Desktop.java:3665)
at com.mathworks.mwswing.desk.Desktop$38.call(Desktop.java:3656)
at com.mathworks.mwswing.desk.Desktop.deferredCall(Desktop.java:7055)
at com.mathworks.mwswing.desk.Desktop.saveLayout(Desktop.java:3655)
at com.mathworks.mwswing.desk.DTLayoutSaveManager.performSave(DTLayoutSaveManager.java:127)
at com.mathworks.mwswing.desk.DTLayoutSaveManager.access$500(DTLayoutSaveManager.java:18)
at com.mathworks.mwswing.desk.DTLayoutSaveManager$1.actionPerformed(DTLayoutSaveManager.java:47)
at javax.swing.Timer.fireActionPerformed(Unknown Source)
at javax.swing.Timer$DoPostEvent.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space
And I cannot see all the rest, such as bayesian irf etc. I tried with 3000 replications and it works. How can I fix this problem and run at least 250000 mh replications for 2 blocks?
Thanks in advance for your help.
Lara
PS: I am using dynare version 4.3.1 (it also happened in version 4.2.4). The last time I was running 300000 mh replications for 2 blocks was a month ago and it was working.