emcee icon indicating copy to clipboard operation
emcee copied to clipboard

labels for parameters in nDim

Open PS-OnGit opened this issue 5 years ago • 2 comments

Hello Is there any possibility to label the different fitting dimension and save them with the hdf backend? This feature would help to evaluate the different walker chains after the fit was complete, if there is a dynamic number of parameters.

kind regards, Paul

PS-OnGit avatar Nov 09 '20 10:11 PS-OnGit

This isn't supported out of the box, but you should be able to arrange something like this by writing to the back end directly. You could try something like:

with backend.open("a") as f:
    f.create_dataset("parameter_names", data=names)

dfm avatar Nov 09 '20 11:11 dfm

Thank you very much for the fast answer.

Since there are some problems with the string format in hdf files, I used another workaround: with backend.open('a') as f: f.attrs.create(name="parameter_names", data=names)

where names could be of any type

PS-OnGit avatar Nov 09 '20 14:11 PS-OnGit