Python parser of a vex file keeping the comment lines.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Benito Marcote 49bcfb65a2 Name change vex->pyvexfile 7 months ago
LICENSE added LICENSE file 3 years ago
MANIFEST Initial commit 3 years ago
README.md Name change vex->pyvexfile 7 months ago
pyvexfile.py Name change vex->pyvexfile 7 months ago
setup.py Name change vex->pyvexfile 7 months ago

README.md

pyVexfile

The vex module is a parser for VEX files that is written completely in Python. It parses a VEX file into a Vex object, storing all the inputs as an (ordered) dictionary structure. This module does not validate the VEX file, in particular it does not check if the block names and parameter names are actually defined by the VEX standard (https://vlbi.org/vex). All parameters are stored as strings, without further evaluation.

Usage

import vexfile

v = vexfile.Vex(vexfilename)

Now you can go through all the sections of the VEX file as

v['STATION']['Jb']...

Note that all comments from the VEX file are kept, and will be shown as different entries named ‘comment-##', where ## is the number of the comment line within the respective section/definition.