def test_dgnss_sanity():
    log_datafile = "./data/serial_link_log_20150314-190228_dl_sat_fail_test1.log.json.dat"
    filename = log_datafile + ".hdf5"
    assert os.path.isfile(filename)
    with pd.HDFStore(filename) as store:
        assert store
        assert isinstance(store.base_obs, pd.Panel)
        assert store.keys()
        assert d.process_dgnss(store)
        assert store.keys()
def test_dgnss_sanity():
    log_datafile \
      = "./data/serial_link_log_20150314-190228_dl_sat_fail_test1.log.json.dat"
    filename = log_datafile + ".hdf5"
    assert os.path.isfile(filename)
    with pd.HDFStore(filename) as store:
        assert store
        assert isinstance(store.base_obs, pd.Panel)
        assert store.keys()
        assert d.process_dgnss(store)
        assert store.keys()
def main():
  import argparse
  parser = argparse.ArgumentParser(description='Swift Nav DGNSS sim tool.')
  parser.add_argument('file',
                      help='Specify the log file to use.')
  args = parser.parse_args()
  log_datafile = args.file
  with pd.HDFStore(log_datafile) as store:
    # assert validate_table_schema(store, _EXPECTED_KEYS), \
    #     "Invalid schema! %s" % store.keys()
    try:
      baselines = process_dgnss(store)
      store.put('rover_rtk_ecef_sim', pd.DataFrame(baselines))
    except (KeyboardInterrupt, SystemExit):
      print "Exiting!"
      sys.exit()