Classes to read IBIsCO / YASP binary trajectories.
Reads coordinates, velocities and more (see attributes of the
Timestep).
-
class MDAnalysis.coordinates.TRZ.Timestep(arg, **kwargs)[source]
TRZ custom Timestep
-
frame
Index of current frame number (1 based)
-
time
Current system time in ps
-
numatoms
Number of atoms in the frame (will be constant throughout trajectory)
-
pressure
System pressure in pascals
-
pressure_tensor
Array containing pressure tensors in order: xx, xy, yy, xz, yz, zz
-
total_energy
Hamiltonian for the system in kJ/mol
-
potential_energy
Potential energy of the system in kJ/mol
-
kinetic_energy
Kinetic energy of the system in kJ/mol
-
temperature
Temperature of the system in Kelvin
-
dimensions[source]
Unit cell dimensions [A,B,C,alpha,beta,gamma].
-
class MDAnalysis.coordinates.TRZ.TRZReader(trzfilename, numatoms=None, convert_units=None, **kwargs)[source]
Reads an IBIsCO or YASP trajectory file
Data : |
- ts
Timestep object
containing coordinates of current frame
|
Methods : |
- len(trz)
returns the number of frames
- for ts in trz
iterates through the trajectory
- for ts in trz[start:stop:skip]
iterate through a trajectory using slicing
- trz[i]
random access of a trajectory frame
|
Creates a TRZ Reader
Arguments : |
- trzfilename
name of input file
- numatoms
number of atoms in trajectory, must taken from topology file!
- convert_units
converts units to MDAnalysis defaults
|
-
close()[source]
Close trz file if it was open
-
delta[source]
MD integration timestep
-
dt[source]
The amount of time between frames in ps
Assumes that this step is constant (ie. 2 trajectories with different steps haven’t been
stitched together)
Returns 0 in case of IOError
-
numatoms[source]
Number of atoms in a frame
-
numframes[source]
Total number of frames in a trajectory
-
open_trajectory()[source]
Open the trajectory file
-
skip_timestep[source]
Timesteps between trajectory frames
-
class MDAnalysis.coordinates.TRZ.TRZWriter(filename, numatoms, title='TRZ', convert_units=None)[source]
Writes a TRZ format trajectory.
Methods : | W = TRZWriter(trzfilename, numatoms, title='TRZ') |
Create a TRZWriter
Arguments : |
- filename
name of output file
- numatoms
number of atoms in trajectory
|
Keywords : |
- title
title of the trajectory
- convert_units
units are converted to the MDAnalysis base format; None selects
the value of MDAnalysis.core.flags [‘convert_lengths’].
(see Flags)
|
-
close()[source]
Close if it was open
-
class MDAnalysis.coordinates.TRZ.TRZReader(trzfilename, numatoms=None, convert_units=None, **kwargs)[source]
Reads an IBIsCO or YASP trajectory file
Data : |
- ts
Timestep object
containing coordinates of current frame
|
Methods : |
- len(trz)
returns the number of frames
- for ts in trz
iterates through the trajectory
- for ts in trz[start:stop:skip]
iterate through a trajectory using slicing
- trz[i]
random access of a trajectory frame
|
Creates a TRZ Reader
Arguments : |
- trzfilename
name of input file
- numatoms
number of atoms in trajectory, must taken from topology file!
- convert_units
converts units to MDAnalysis defaults
|
-
close()[source]
Close trz file if it was open
-
delta[source]
MD integration timestep
-
dt[source]
The amount of time between frames in ps
Assumes that this step is constant (ie. 2 trajectories with different steps haven’t been
stitched together)
Returns 0 in case of IOError
-
numatoms[source]
Number of atoms in a frame
-
numframes[source]
Total number of frames in a trajectory
-
open_trajectory()[source]
Open the trajectory file
-
skip_timestep[source]
Timesteps between trajectory frames
-
class MDAnalysis.coordinates.TRZ.TRZWriter(filename, numatoms, title='TRZ', convert_units=None)[source]
Writes a TRZ format trajectory.
Methods : | W = TRZWriter(trzfilename, numatoms, title='TRZ') |
Create a TRZWriter
Arguments : |
- filename
name of output file
- numatoms
number of atoms in trajectory
|
Keywords : |
- title
title of the trajectory
- convert_units
units are converted to the MDAnalysis base format; None selects
the value of MDAnalysis.core.flags [‘convert_lengths’].
(see Flags)
|
-
close()[source]
Close if it was open
-
class MDAnalysis.coordinates.TRZ.Timestep(arg, **kwargs)[source]
TRZ custom Timestep
-
dimensions[source]
Unit cell dimensions [A,B,C,alpha,beta,gamma].