Example parameter files¶
Example for reconstruction of series¶
This is basically the example from the _sec-tutorial, but without defocus adjustment:
{
// Path of hologram files (using printf format, integer argument). Required.
"object_names" : "holo_%03d.dm3",
// Index of first hologram.
"object_first" : 1,
// Index of last hologram. Required.
"object_last" : 20,
// Same (name, first index, last index) for "empty" holograms.
"empty_names" : "empty_%03d.dm3",
"empty_first" : 1,
"empty_last" : 20,
// Sampling (nm/px) of object holograms.
// Defaults to value in data files.
//"sampling" : 0.00519824,
// Voltage in kV. Default to value recorded in data files.
//"voltage": 300,
// Size (in px) used for reconstruction of "empty" holograms. Required.
"empty_size" : 512,
// Size (in px) used for reconstruction of "object" holograms Required.
"object_size" : 384,
// X, Y Position of sideband in FFT pixels (origin is in center). Required.
"sideband_pos" : [1136, 1304],
// Reconstruction region in pixels (L, T, R, B). Defaults to full region.
"roi" : [128, 128, 1920, 1920],
// Region for raw alignment in pixels (L, T, R, B). Defaults to roi.
//"align_roi" : [256, 256, 1536, 1536],
// Disable raw alignment. Raw alignment is enabled by default.
//"enable_raw_alignment" : false,
// Output file name (will be HDF5 file). Required.
"output_name" : "holo.hdf5",
// Mask type (see FilterFunction for details). Defaults to "EDGE"
// "filter_func" : "EDGE",
"filter_func" : ["BUTTERWORTH", 14],
// cut off frequency in 1/nm (q_max). Required.
"cut_off" : 14.5,
// Parameterization for MTF
"mtf" : [["CONSTANT", -2.25536738e-02],
["LORENTZIAN", 1.02543658e-05, 1.15367655e-04],
["LORENTZIAN", 2.49224357e-02, 5.35262063e-02],
["GAUSSIAN", 4.60461599e-01, 4.36842560e+02]],
// Correct phase by empty phase only (true), or full complex reconstruction (false).
// Defaults to false.
"only_phase": false,
}
Only reconstruct empty hologram¶
This will reconstruct only the empty hologram. This can be used in for instance in subsequent reconstructions (see other examples):
{
// Leave "object_names" unset
// Usual empty hologram input
"empty_names" : "empty.%d.dm3",
"empty_first" : 1,
"empty_last" : 10,
// Size (in px) used for reconstruction of "empty" holograms. Required.
"empty_size" : 1536,
// X, Y Position of side band in FFT pixels (origin is in center). Required.
"sideband_pos" : [1011, 1091],
// Output file name (will be HDF5 file). Empty hologram will be in dataset "empty"
"output_name" : "my_empty_reco.hdf5",
// Mask type (see FilterFunction for details). Defaults to "EDGE"
"filter_func" : ["BUTTERWORTH", 14],
// Reconstruction cutoff in 1/nm
"cut_off" : 3.0,
// Parameterization for MTF
// "mtf" : ...
}
Use pre-reconstructed empty hologram for normalization¶
This example uses a prereconstructed empty hologram for normalization (also see Normalization):
{
// Object holograms (as usual). Here series of DM3 files
"object_names" : "hologram.%d.dm3", // Filename format
"object_first" : 1, // Index of first
"object_last" : 5, // Index of last (inclusive)
// Use pre-reconstructed empty hologram for normalization, here dataset from HDF5 file.
"empty_override" : "somefile.hdf5?dataset=empty",
// Reconstruction parameters
"object_size" : 1536, // Reconstruction size in px
"sideband_pos" : [1011, 1091], // X, Y Position of side band in FFT pixels (origin is in center).
"cut_off" : 3.0, // Reconstruction cut off in 1/nm
"filter_func" : ["BUTTERWORTH", 14], // Mask type
// Optional reconstruction region (L, T, R, B). Defaults to full region.
//"roi" : [166, 388, 1701, 1923],
// Output file name (will be HDF5 file). Required.
"output_name" : "my_reco.hdf5",
// Parameterization for MTF
//"mtf" : ...
}
Use predetermined camera distortions for normalization¶
This example creates an synthetic empty hologram for normalization. The synthetic empty hologram is creacted from predetermined camera distortions (also see Normalization):
{
// Object holograms (as usual). Here series of DM3 files
"object_names" : "hologram.%d.dm3", // Filename format
"object_first" : 1, // Index of first
"object_last" : 5, // Index of last (inclusive)
// Enable synthetic empty holograms
"synthesize_empty": true,
// Two datasets, same size as holograms, with displacements in px for each pixel
// First in X direction, Second in Y direction
"camera_distortions": ["camera.hdf5?dataset=dx", "camera.hdf5?dataset=dy"],
// Reconstruction parameters (as usual)
"object_size" : 1536, // Reconstruction size in px
"sideband_pos" : [1011, 1091], // X, Y Position of side band in FFT pixels (origin is in center).
"cut_off" : 3.0, // Reconstruction cut off in 1/nm
"filter_func" : ["BUTTERWORTH", 14], // Mask type
// Optional reconstruction region (L, T, R, B). Defaults to full region.
//"roi" : [166, 388, 1701, 1923],
// Output file name (will be HDF5 file). Required.
"output_name" : "my_reco.hdf5",
// Parameterization for MTF
//"mtf" : ...
}
Only reconstruct single hologram (no averaging)¶
This example reconstructs a single (object) hologram, and normalizes with a single empty hologram:
{
// Output file name (will be HDF5 file). Required.
"output_name" : "output.hdf5",
// List with just a single filename
"object_names" : ["my_hologram.dm3"],
// Empty hologram (list with single filename)
"object_names" : ["empty.dm3"],
// Reconstruction parameters
"object_size" : 512,
"sideband_pos" : [749, 1019],
"filter_func" : ["BUTTERWORTH", 14],
"cut_off" : 1.0
}