parmed.amber.Rst7

class parmed.amber.Rst7(filename=None, natom=None, title='', time=0.0)[source]

Amber input coordinate (or restart coordinate) file. Front-end for the readers and writers, supports both NetCDF and ASCII restarts.

Parameters
filenamestr, optional

If a filename is provided, this file is parsed and the Rst7 data populated from that file. The format (ASCII or NetCDF) is autodetected

natomint, optional

If no filename is provided, this value is required. If a filename is provided, this value is ignored (and instead set to the value of natom from the coordinate file). This is the number of atoms for which we have coordinates. If not provided for a new file, it must be set later.

titlestr, optional

For a file that is to be written, this is the title that will be given to that file. Default is an empty string

timefloat, optional

The time to write to the restart file. This is cosmetic. Default is 0

Attributes
box
box_vectors

Unit cell vectors with units

hasbox

Whether or not this Rst7 has unit cell information

hasvels

Whether or not this Rst7 has velocities

positions

Atomic coordinates with units

velocities

Atomic velocities in units of angstroms/picoseconds

Methods

copy_from(thing)

Copies the coordinates, velocities, and box information from another instance

open(filename)

Constructor that opens and parses an input coordinate file

write(fname[, netcdf])

Writes the coordinates and/or velocities to a restart file

__init__(filename=None, natom=None, title='', time=0.0)[source]

Optionally takes a filename to read. This is deprecated, though, as the alternative constructor “open” should be used instead

Methods

__init__([filename, natom, title, time])

Optionally takes a filename to read.

copy_from(thing)

Copies the coordinates, velocities, and box information from another instance

open(filename)

Constructor that opens and parses an input coordinate file

write(fname[, netcdf])

Writes the coordinates and/or velocities to a restart file

Attributes

box

box_vectors

Unit cell vectors with units

hasbox

Whether or not this Rst7 has unit cell information

hasvels

Whether or not this Rst7 has velocities

positions

Atomic coordinates with units

velocities

Atomic velocities in units of angstroms/picoseconds