vacf_output_file_writer

A module containing the classes for writing related to an VACF analysis to a file.

Summary

Classes:

VACFDataWriter

Class for writing the data of an VACF analysis to a file.

VACFLogWriter

Class for writing the log (setup parameters) of an VACF analysis to a file.

VACFSpectrumDataWriter

Class for writing the spectrum of an VACF analysis to a file.

VACFWindowedDataWriter

Class for writing the windowed (apodized) correlation function of an VACF analysis to a file.

Reference

class VACFDataWriter(filename: str)[source]

Bases: BaseWriter

Class for writing the data of an VACF analysis to a file.

The output file is written in the legacy FreqCalc/Fluxfreqcalc format: one row per lag with the columns lag time in ps and normalized VACF.

Parameters:

filename (str) – the filename to write to

write(
data: tuple[Np1DNumberArray, Np1DNumberArray],
)[source]

Writes the data to the file.

Parameters:

data (Tuple[Np1DNumberArray, Np1DNumberArray]) – the time axis and correlation function output from the VACF.run() method

class VACFLogWriter(filename: str | None)[source]

Bases: BaseWriter

Class for writing the log (setup parameters) of an VACF analysis to a file.

Parameters:

filename (str | None) – the filename to write to if None, the output is printed to stdout

write_after_run(
vacf: VACF,
)[source]

Writes the log after the VACF run() method is called.

This includes the number of time origins and the elapsed time of the VACF run() method.

Parameters:

vacf (VACF) – the VACF analysis object

write_before_run(
vacf: VACF,
)[source]

Writes the log before the VACF run() method is called.

This includes the general header of PQAnalysis and the most important setup parameters of the VACF analysis.

Parameters:

vacf (VACF) – the VACF analysis object

class VACFSpectrumDataWriter(filename: str)[source]

Bases: BaseWriter

Class for writing the spectrum of an VACF analysis to a file.

The output file is written in the legacy ft.f format: one row per frequency index with the columns wavenumber in cm^-1 and amplitude.

Parameters:

filename (str) – the filename to write to

write(
data: tuple[Np1DNumberArray, Np1DNumberArray],
)[source]

Writes the spectrum to the file.

Parameters:

data (Tuple[Np1DNumberArray, Np1DNumberArray]) – the wavenumbers and amplitudes output from the vacf_spectrum() function

class VACFWindowedDataWriter(filename: str)[source]

Bases: BaseWriter

Class for writing the windowed (apodized) correlation function of an VACF analysis to a file.

The output file is written in the legacy ft.f windowfile format: one row per lag with the columns lag time in ps and windowed correlation function.

Parameters:

filename (str) – the filename to write to

write(
data: tuple[Np1DNumberArray, Np1DNumberArray],
)[source]

Writes the windowed correlation function to the file.

Parameters:

data (Tuple[Np1DNumberArray, Np1DNumberArray]) – the time axis and the windowed correlation function output from the vacf_spectrum() function