https://github.com/RadioAstronomySoftwareGroup/pyuvdata
Revision 4f78a34f2691fedfeb27e11e6f99fe9ea6f6499c authored by Matthew Kolopanis on 16 May 2019, 17:46:15 UTC, committed by Bryna Hazelton on 22 May 2019, 18:57:04 UTC
1 parent 33f73e2
Tip revision: 4f78a34f2691fedfeb27e11e6f99fe9ea6f6499c authored by Matthew Kolopanis on 16 May 2019, 17:46:15 UTC
removed unused param, added comment about yield/de
removed unused param, added comment about yield/de
Tip revision: 4f78a34
readwrite_uvfits.py
#! /usr/bin/env python
# -*- mode: python; coding: utf-8 -*
# Copyright (c) 2018 Radio Astronomy Software Group
# Licensed under the 2-clause BSD License
from __future__ import absolute_import, division, print_function
import argparse
import os.path as op
from pyuvdata import UVData
parser = argparse.ArgumentParser()
parser.add_argument('uvfits_read',
help='name of a uvfits file to read in')
parser.add_argument('uvfits_write',
help='name of a uvfits file to write out')
args = parser.parse_args()
uvfits_file_in = args.uvfits_read
if not op.isfile(uvfits_file_in):
raise IOError('There is no file named {}'.format(args.uvfits_file_in))
uvfits_file_out = args.uvfits_write
this_uv = UVData()
this_uv.read_uvfits(uvfits_file_in)
this_uv.write_uvfits(uvfits_file_out)
del(this_uv)
Computing file changes ...