STSim¶
-
class
pyrost.simulation.STSim(params, **kwargs)¶ One-dimensional Speckle Tracking scan simulation class. Generates barcode’s transmission profile and lens’ abberated wavefront, whereupon propagates the wavefront to the detector’s plane.
- Parameters
st_params (STParams) – Experimental parameters.
bsteps (numpy.ndarray, optional) – Array of barcode’s bar coordinates. Generates the array automatically if it’s not provided.
Notes
Necessary attributes:
params : Experimental parameters.
Optional attributes:
b_steps : Barcode’s bar positions [um].
b_profile : Barcode’s transmission profile.
det_wfx : Wavefront at the detector’s plane along the x axis.
det_wfy : Wavefront at the detector’s plane along the y axis.
det_iy : Intensity profile at the detector’s plane along the x axis.
det_iy : Intensity profile at the detector’s plane along the y axis.
lens_wfx : Wavefront at the lens’ plane along the x axis.
lens_wfy : Wavefront at the lens’ plane along the y axis.
n_x : Wavefront size along the x axis.
n_y : Wavefront size along the y axis.
sample_wfx : Wavefront at the sample’s plane along the x axis.
sample_wfy : Wavefront at the sample’s plane along the y axis.
See also
st_sim_paramFull list of experimental parameters.
-
update_bar_positions(b_steps)¶ Return a new
STSimobject with the updated b_steps.- Parameters
b_steps (numpy.ndarray) – Array of barcode’s bar positions.
- Returns
A new
STSimobject with the updated b_steps.- Return type
-
frames(apply_noise=True)¶ Return intensity frames at the detector plane. Applies Poisson noise.
- Returns
Intensity frames.
- Return type
-
ptychograph(apply_noise=True)¶ Return a ptychograph of intensity frames. Applies Poisson noise.
- Returns
Ptychograph.
- Return type