Skip to main content

Parser/transformator for MAD-X sequences

Project description


Script to parse MAD-X sequences from a source file and perform simple transformations on the elements.


  • docopt to parse command line options

  • pydicti to store and access element attributes


The setup is to be performed as follows

python install


The command should be called as follows:

Usage: [-j <json>] [-o <output] [<input>] (--help | --version)

    -o <output>, --output=<output>  Set output file
    -j <json>, --json=<json>        Set JSON output file
    -h, --help                      Show this help
    -v, --version                   Show version information
    python -m madseq <infile.madx >outfile.madx

If <input> is not specified the standard input stream will be used to read the input file. Respectively, the standard output stream will be used if <output> is not specified.


  • Do not use multi line commands in the input sequences. At the moment these are not parsed correctly!

  • Do not add any at= position arguments in the input sequences. The madseq script takes care of this responsibility.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

madseq-0.1.tar.gz (8.7 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page