Documentation
¶
Index ¶
Constants ¶
const ( TrajUnIniRead = "Traj object uninitialized to read" TrajUnIniWrite = "Traj object uninitialized to read" ReadError = "Error reading frame" UnableToOpen = "Unable to open file" SecurityCheckFailed = "Failed Security Check" NilCoordinates = "Given nil coordinates" WrongFormat = "Wrong format in the STF file or frame" NotEnoughSpace = "Not enough space in passed blocks" EOF = "EOF" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Error ¶
type Error struct {
// contains filtered or unexported fields
}
Error is the general structure for DCD trajectory errors. It fullfills chem.Error and chem.TrajError
type StfR ¶
type StfR struct {
// contains filtered or unexported fields
}
Read!
func New ¶
New opens a STF trajectory for reading, and returns a pointer to the handle, a map with the metadata (or nil, if no metadata is found) and error or nil.
func (*StfR) Next ¶
Next puts in the given matrix (c) the coordinates for the next frame of the trajectory and, if given, and the information is present, puts the box vector information in box Returns error if the operation is not successful. If the error is EOF, the end of the trajectory has been reached, not an actual error.
func (*StfR) NextConc ¶
NextConc takes a slice of bools and reads as many frames as elements the list has form the trajectory. The frames are discarted if the corresponding elemetn of the slice is false. The function returns a slice of channels through each of each of which a *matrix.DenseMatrix will be transmited
type StfW ¶
type StfW struct {
// contains filtered or unexported fields
}
Write!
func NewWriter ¶
func NewWriter(name string, natoms int, header map[string]string, Opts ...*WriterOptions) (*StfW, error)
For zstandard (stf) compression levels are progressively slower but offering better compression as compressionLevel increases from 1 to 4 (other numbers will result in '1' or fastest compression). If the precision is specified in the header, that overwrites whatever is in the options.
type WriterOptions ¶ added in v0.7.2
type WriterOptions struct {
// Precision int //How many decimals for each coordinate, in Angstroms
CompressionLevel int // 1: Fastest/Worst compression to 4: Slowest/Best compression
}
func DefaultWriterOptions ¶ added in v0.7.2
func DefaultWriterOptions() *WriterOptions
func (*WriterOptions) Fix ¶ added in v0.7.2
func (O *WriterOptions) Fix()