lspestrip / striptease

Strip TEst Analysis for System Evaluation
MIT License
4 stars 3 forks source link

Add a new tool, query_db.py #67

Closed ziotom78 closed 2 years ago

ziotom78 commented 2 years ago

This PR adds a new command-line program, query_db.py, which is able to query a SQLite3 database of HDF5 files and produce a table that shows when a polarimeter was on.

The tool must be called from the command line, specifying the polarimeters to consider with -p (default is to consider all the polarimeters) and the path to the file index.db, which must be created using build_hdf5_db.py. Here is an example of the output:

query_database

The code can output the table in JSON format using the flag --json.

It would be nice to extend it so that it can produce something like this image (taken from the timeline repository):

timeline_example

However, i do not think I will do it in this PR.