This is a simple script to convert single particle data into specified h5 format. The data field is given below, which can be extended if you'd like.

Convert single particle patterns into hdf5 format file. The structure of the output h5 file is as follows:
        3D data with shape (Np, Nx, Ny) where Np is the number of patters, and Nx, Ny are the size of first and second axis.
        classification results of the data with shape (Np,). -1 for unclassified, 0 for no particle, 1 for single particle, 2 for multiple particle
        Number of paterns with no particle.
        Number of patterns with single particle.
        Number of patterns with multiple particles.
        Number of patterns unclassified.
        Number of totoal patterns.
        Optional. The XFEL wavelength in angstrom(1E-10m).
    'detector distance':
        Optional. The detector distance to intersection point in mm.

Download the script here.

Richard Feynman

“everything that is living can be understood in terms of the jiggling and wiggling of atoms”.

and now, we want to watch atoms jiggling and wiggling.

X-rays, electrons, fluorescence light, the advances of photon sciences, together with computational modeling, are making this happen.