Error in MCMC diagnostics: Parallel


after running MCMC with load_mh_file I get the following error

[quote]MH: I’m loading past metropolis-hastings simulations…
MH: … It’s done. I’ve loaded 1305000 simulations.

ssh @localhost rm -f //random_walk_metropolis_hastings_core_output_.mat: Signal 127
ssh @localhost rm -f //comp_status_random_walk_metropolis_hastings_core
.mat: Signal 127
ssh @localhost rm -f //slaveParallel_break.mat: Signal 127
MH: Number of mh files : 828 per block.
MH: Total number of generated files : 4968.
MH: Total number of iterations : 1310000.
MH: average acceptation rate per chain :
0.5585 0.5915 0.5809 0.5951 0.5877 0.5817

MCMC Diagnostics: Univariate convergence diagnostic, Brooks and Gelman (1998):
ssh @localhost rm -f //McMCDiagnostics_core_output_.mat: Signal 127
ssh @localhost rm -f //comp_status_McMCDiagnostics_core
.mat: Signal 127
ssh @localhost rm -f //slaveParallel_break.mat: Signal 127
Job number 1 crashed with error:
Error using load
Unable to read file ECB_IPAM/metropolis/ECB_IPAM_mh444_blck1.mat: No such file or directory.

ans =

file: '/jobdata/dynare-4.3.3/matlab/McMCDiagnostics_core.m'
name: 'McMCDiagnostics_core'
line: 87

ans =

file: '/jobdata/dynare-4.3.3/matlab/parallel/fParallel.m'
name: 'fParallel'
line: 73


Any idea of what might have gone wrong?



The problem is not specific to the parallel execution.

Apparently successive runs of MCMC maintaining the old chains generated some inconsistency in the number of saved
chains (the 444 was missing).
The diagnostic file does not check how many files do actually exist and then it crashes when it does not find what expected.

A suggestion for the developers would be to make the diagnostic function use only the chains that actually exist in the folder.



Thanks, we will look into it.