Skip to content

Parse segments

Timothy Davies requested to merge tdv-parse-segments into dev

This adds a bunch of functions to try parsing segments files, and to test whether a list of times is in a gap or not.

It was written without a tonne of planning out, probably room for cleanups/reworks, but probably not worth significantly reworking as it's just for analysis.

I've tested locally, and both the 'parse_segments' and 'test_gps_times' scripts work for me, correctly listing segments from files & whether a few times are active or in gaps.

Sample usage & output: image

python share/scripts/analysis/parse_segments.py /fred/oz016/tdavies/projects/testing/inj/8000_test/spiir_1_1/add-redis/019/H1L1_SEGMENTS_1186642720_7982.xml.gz /fred/oz016/tdavies/projects/testing/inj/8000_test/spiir_1_1/add-redis/013/H1L1_SEGMENTS_1186642720_7982.xml.gz

python share/scripts/analysis/test_gps_times.py /fred/oz016/tdavies/projects/testing/inj/8000_test/spiir_1_1/add-redis/019/ 1186642736 1186642741 1186642733 1186642737 1186642733

The goal is for people to be able to follow the steps in those command line scripts in jupyter (Siqi, Weichangfeng, and Sunil wanted them I think).

Edited by Timothy Davies

Merge request reports