vacf_output_file_writer
A module containing the classes for writing related to an
VACF analysis to a file.
Summary
Classes:
Class for writing the data of an |
|
Class for writing the log (setup parameters) of an |
|
Class for writing the spectrum of an |
|
Class for writing the windowed (apodized) correlation function of an |
Reference
- class VACFDataWriter(
- filename: str,
- export_files: Sequence[str] | None = None,
Bases:
AnalysisDataWriterClass for writing the data of an
VACFanalysis 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 primary output filename. Its extension selects the format.
export_files (Sequence[str] | None, optional) – Additional output filenames, by default None.
- write(
- data: tuple[Np1DNumberArray, Np1DNumberArray],
Writes the data to the file.
- Parameters:
data (Tuple[Np1DNumberArray, Np1DNumberArray]) – the time axis and correlation function output from the VACF.run() method
- header = '# PQAnalysis: Normalized correlation function\n# FIELDS time normalized_correlation\n# SYMBOLS t C(t)∕C(0)\n# UNITS ps 1'
- schema: AnalysisSchema = AnalysisSchema(title='Normalized correlation function', columns=(AnalysisColumn(field='time', symbol='t', unit='ps'), AnalysisColumn(field='normalized_correlation', symbol='C(t)∕C(0)', unit='1')), plot=AnalysisPlotPreset(x_field='time', y_fields=('normalized_correlation',), x_label='t [ps]', y_label='C(t) / C(0)', legends=('C(t) / C(0)',)))
- class VACFLogWriter(filename: str | None)[source]
Bases:
BaseWriterClass for writing the log (setup parameters) of an
VACFanalysis to a file.- Parameters:
filename (str | None) – the filename to write to if None, the output is printed to stdout
- class VACFSpectrumDataWriter(
- filename: str,
- export_files: Sequence[str] | None = None,
Bases:
AnalysisDataWriterClass for writing the spectrum of an
VACFanalysis 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 primary output filename. Its extension selects the format.
export_files (Sequence[str] | None, optional) – Additional output filenames, by default None.
- write(
- data: tuple[Np1DNumberArray, Np1DNumberArray],
Writes the spectrum to the file.
- Parameters:
data (Tuple[Np1DNumberArray, Np1DNumberArray]) – the wavenumbers and amplitudes output from the
vacf_spectrum()function
- header = '# PQAnalysis: VACF spectrum\n# FIELDS wavenumber amplitude\n# SYMBOLS ν̃ |Ĉ(ν̃)|\n# UNITS cm⁻¹ arbitrary'
- schema: AnalysisSchema = AnalysisSchema(title='VACF spectrum', columns=(AnalysisColumn(field='wavenumber', symbol='ν̃', unit='cm⁻¹'), AnalysisColumn(field='amplitude', symbol='|Ĉ(ν̃)|', unit='arbitrary')), plot=AnalysisPlotPreset(x_field='wavenumber', y_fields=('amplitude',), x_label='Wavenumber [cm\\S-1\\N]', y_label='Amplitude [a.u.]', legends=('Amplitude',)))
- class VACFWindowedDataWriter(
- filename: str,
- export_files: Sequence[str] | None = None,
Bases:
AnalysisDataWriterClass for writing the windowed (apodized) correlation function of an
VACFanalysis 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 primary output filename. Its extension selects the format.
export_files (Sequence[str] | None, optional) – Additional output filenames, by default None.
- write(
- data: tuple[Np1DNumberArray, Np1DNumberArray],
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
- header = '# PQAnalysis: Windowed correlation function\n# FIELDS time windowed_correlation\n# SYMBOLS t C(t)w(t)\n# UNITS ps 1'
- schema: AnalysisSchema = AnalysisSchema(title='Windowed correlation function', columns=(AnalysisColumn(field='time', symbol='t', unit='ps'), AnalysisColumn(field='windowed_correlation', symbol='C(t)w(t)', unit='1')), plot=AnalysisPlotPreset(x_field='time', y_fields=('windowed_correlation',), x_label='t [ps]', y_label='C(t)w(t)', legends=('Windowed correlation',)))