simulation.readdy.parser¶
Methods for parsing ReaDDy simulations.
Module Attributes
Parsed tidy data column names. |
|
Parsed tidy data column data types. |
|
Simulation timestep (in ns). |
|
Default simulation volume dimensions (x, y, z). |
|
Total distance the fiber end was displaced in nm. |
Functions
|
Download ReaDDy h5 files from S3 to local path. |
|
Parse ReaDDy simulation data for select conditions and replicates. |
Parse ReaDDy trajectory data into tidy data format. |
- COLUMN_NAMES: list[str] = ['fiber_id', 'xpos', 'ypos', 'zpos', 'xforce', 'yforce', 'zforce', 'segment_curvature', 'time', 'fiber_point']¶
Parsed tidy data column names.
- COLUMN_DTYPES: dict[str, type[float] | type[int]] = {'fiber_id': <class 'int'>, 'fiber_point': <class 'int'>, 'segment_curvature': <class 'float'>, 'time': <class 'float'>, 'xforce': <class 'float'>, 'xpos': <class 'float'>, 'yforce': <class 'float'>, 'ypos': <class 'float'>, 'zforce': <class 'float'>, 'zpos': <class 'float'>}¶
Parsed tidy data column data types.
- READDY_TIMESTEP: float = 0.1¶
Simulation timestep (in ns).
- BOX_SIZE: ndarray = array([600., 600., 600.])¶
Default simulation volume dimensions (x, y, z).
- COMPRESSION_DISTANCE: float = 150.0¶
Total distance the fiber end was displaced in nm.
- download_readdy_hdf5(bucket: str, series_name: str, series_key: str, rep_ix: int, download_path: str) str | None [source]¶
Download ReaDDy h5 files from S3 to local path.
The ReaDDy Python package currently requires a local file path.
- Parameters:
bucket – Name of S3 bucket for input and output files.
series_name – Name of simulation series.
series_key – Combination of series and condition names.
rep_ix – Replicate index.
download_path – Path for downloading temporary h5 files.
- parse_readdy_simulation_single_fiber_trajectory(bucket: str, series_name: str, series_key: str, rep_ix: int, n_timepoints: int, n_monomer_points: int, total_steps: int, temp_path: str, timestep: float = 0.1) DataFrame [source]¶
Parse ReaDDy trajectory data into tidy data format.
Note that this methods assumes there is only one fiber in the simulation.
- Parameters:
bucket – Name of S3 bucket for input and output files.
series_name – Name of simulation.
series_key – Series key.
rep_ix – Replicate index.
n_timepoints – Number of equally spaced timepoints to sample.
n_monomer_points – Number of equally spaced monomer points to sample.
total_steps – Total number of steps for each given simulation.
temp_path – Path for saving temporary h5 files.
timestep – Simulation timestep (in ns).
- parse_readdy_simulation_data(bucket: str, series_name: str, condition_keys: list[str], n_replicates: int, n_timepoints: int, n_monomer_points: int, compression: bool, temp_path: str) None [source]¶
Parse ReaDDy simulation data for select conditions and replicates.
- Parameters:
bucket – Name of S3 bucket for input and output files.
series_name – Name of simulation series.
condition_keys – List of condition keys.
n_replicates – Number of simulation replicates.
n_timepoints – Number of equally spaced timepoints to sample.
n_monomer_points – Number of equally spaced monomer points to sample.
compression – True if simulations are compressed, False otherwise.
temp_path – Path for saving temporary h5 files.