Beispiel #1
0
def main():
    logger = logger_defaults.getProgramLogger("observe", 
            loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1a", "1f", "1c", "2a", "2h", "1k", "5c", "4g", "4j"]
    #freqs = [950, 950, 1600, 1600, 1600, 1600, 950, 950, 1600]

    #ant_list = ["1a", "1f", "1c", "2a", "2h", "1k", "5c", "4g", "4j", "1h"]
    #freqs = [950, 950, 1600, 1600, 1600, 1600, 950, 950, 1600, 1600]

    ant_list = ["1a", "1f", "5c",   "1c", "2a", "4j",    "2h", "1k", "1h"]
    freqs = [950]*3 + [1600]*3 + [2250]*3

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas,ant_list, True)

    source = "frb180916"
    snap_dada.set_freq_auto(freqs, ant_list)
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list)
    obs_time = 1200
    nhours = 3
    ncycles = 2

    for icycle in range(ncycles):
        for i in range(nhours*3):
            snap_if.tune_if_ants(ant_list)
            utc = snap_dada.start_recording(ant_list, obs_time, 
                    npolout=1, acclen=120, disable_rfi=True)
            snap_dada.mark_obs_for_heimdall(utc)

        time.sleep(1200)
Beispiel #2
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    ant_list = ["1f", "1h", "1c"]  #, "1k", "5c"]
    freqs = [950, 1300, 1650]  #, 1600, 950]

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    source = "J0332+5434"
    ata_control.make_and_track_ephems(source, ant_list)

    #ata_control.set_freq(freqs, ant_list)
    snap_dada.set_freq_auto(freqs, ant_list)

    ata_control.autotune(ant_list)
    snap_if.tune_if_ants(ant_list)
    obs_time = 300

    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=1,
                                    acclen=24,
                                    disable_rfi=True)
Beispiel #3
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation

    ant_list = ["3c"]
    #freqs = [1500]
    #ata_control.autotune(ant_list, -12)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    #snap_dada.set_freq_auto(freqs, ant_list)
    snap_if.tune_if_ants(ant_list, 12)
    obs_time = 30

    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=2,
                                    acclen=120 * 16,
                                    disable_rfi=True)
    _ = input("Press any key for hot measurement")
    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=2,
                                    acclen=120 * 16,
                                    disable_rfi=True)
Beispiel #4
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1f", "1h"]#, "1k", "5c"]
    #freqs =    [950, 1600]#, 1600, 950]

    #ant_list = ["1a",    "4j",    "1k"]
    #freqs = [950] + [1600] + [2250]
    ant_list = ["1f", "5c", "1a", "1c", "2a", "4j", "2h", "1k", "1h"]
    #freqs = [950]*3 + [1600]*3 + [2250]*3
    freqs = [1400] * len(ant_list)

    #ant_list = ["1f", "1k"]
    #freqs = [950, 1600]
    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    source = "j0534+2200"
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list)
    snap_dada.set_freq_auto(freqs, ant_list)
    snap_if.tune_if_ants(ant_list)
    obs_time = 1800

    #for i in range(3):
    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=1,
                                    acclen=40,
                                    disable_rfi=True)
Beispiel #5
0
def main():
    logger = logger_defaults.getProgramLogger("observe", 
            loglevel=logging.INFO)

    ant_list = ["1a", "1f", "1c", "2a", "2b", "2h",
            "3c", "4g", "1k", "5c", "1h", "4j"]

    #ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas,ant_list, False)

    ata_control.set_az_el(ant_list, 180, 75)

    ata_control.autotune(ant_list)

    freqs = np.arange(2250, 11200, 550)

    snap_dada.set_freq_auto([freqs[0]]*len(ant_list), ant_list)
    time.sleep(30)
    
    o = open("output_snap_if.txt","w")

    for ifreq, freq in enumerate(freqs):
        time.sleep(10)
        snap_dada.set_freq_auto([freq]*len(ant_list), ant_list)
        snap_if.tune_if_ants(ant_list)
        o.write(str(freq))
        o.write(str(snap_if.getatten(ant_list)))

    o.close()
Beispiel #6
0
def main():
    logger = logger_defaults.getProgramLogger("observe", 
            loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1a", "1k", "5c", "1h", "4j", "3d", "4g", "2h", "2a", "2b", "1c"]
    #ant_list = ["1a", "1f", "2a", "2h", "3d", "4g", "1k", "5c", "1h", "2b"]
    ant_list = ['1a', '1f', '1c', '1h',  '2a', '4j', '2h', '3d', '4g', '5c', '2b']

    #freqs = [2000]*len(ant_list)
    freqs = [1500]*len(ant_list)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas,ant_list, True)

    # observe a pulsar
    #source = "J1935+1616"
    #source = "J0332+5434"
    #ata_control.make_and_track_ephems(source, ant_list)
    #ata_control.autotune(ant_list, power_level=-15)
    #snap_dada.set_freq_auto(freqs, ant_list)
    #snap_if.tune_if_ants(ant_list)
    #utc = snap_dada.start_recording(ant_list, 600,
    #                    npolout=1, acclen=120, disable_rfi=True)


    # now to FRB source
    #source = "frb180916"
    source = "J1934+2153"
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list, power_level=-15)
    snap_dada.set_freq_auto(freqs, ant_list)
    snap_if.tune_if_ants(ant_list)
    obs_time = 1200
    nhours = 3
    ncycles = 3

    for icycle in range(ncycles):
        for i in range(nhours*3):
            snap_if.tune_if_ants(ant_list)
            utc = snap_dada.start_recording(ant_list, obs_time, 
                    npolout=1, acclen=120, disable_rfi=True)
            Path('/mnt/buf0/obs/%s/obs.sumall' %utc).touch()
            snap_dada.mark_obs_for_heimdall(utc)


        time.sleep(300)
Beispiel #7
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    """
    ant_list = ["1a","1f","5c"]
    freqs = [950]*3

    ant_list += ["2h", "1k", "1h"]
    freqs += [1300]*3

    ant_list += ["1c", "2a", "4j"]
    freqs += [1650]*3
    """

    #ant_list = ["1f", "2a", "1k", "5c"]
    #freqs = [950, 1600, 1600, 950]
    #ant_list = ["1a", "1f", "1c", "2a", "2b", "2h", "3c",
    #        "1k", "5c", "4g", "4j", "1h"]
    #freqs = [1400]*len(ant_list)

    #ant_list = ["1f", "5c", "1a",   "1c", "2a", "4j",    "2h", "1k", "1h"]
    #freqs = [950]*3 + [1600]*3 + [2250]*3

    ant_list = [
        "1a", "1f", "1c", "2a", "2h", "3d", "5c", "2b", "1h", "4g", "4j"
    ]
    freqs = [1500] * len(ant_list)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, True)

    source = "J1935+1616"
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list)
    snap_dada.set_freq_auto(freqs, ant_list)
    time.sleep(30)

    snap_if.tune_if_ants(ant_list)
    obs_time = 300

    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=1,
                                    acclen=120,
                                    disable_rfi=True)
Beispiel #8
0
def main():
    logger = logger_defaults.getProgramLogger("observe", 
            loglevel=logging.INFO)

    # pulsar observation

    ant_list = ["3c"]
    freqs = [1000]

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    snap_dada.set_freq_auto(freqs, ant_list)
    snap_if.tune_if_ants(ant_list)
    obs_time = 30

    utc = snap_dada.start_recording(ant_list, obs_time, 
            npolout=1, acclen=120, disable_rfi=True)
Beispiel #9
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation

    ant_list = ["3c"]

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    source = "J1935+1616"
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list)
    snap_if.tune_if_ants(ant_list)

    obs_time = 600

    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=1,
                                    acclen=120,
                                    disable_rfi=True)
Beispiel #10
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1a", "1f", "5c",     "1c", "2a", "4j",     "2h", "1k", "1h"]
    #ant_list = ["3c", "2b"]
    #ant_list = ["1a", "1f", "1c", "2b",
    #        "1k", "5c", "1h", "4j", "2a", "3d", "4g", "2h"]
    #ant_list = ["1a", "1f", "1k", "5c", "1h", "4j", "3d", "4g", "2h", "2a", "1c", "2b"]
    ant_list = [
        "1a", "1f", "5c", "1h", "4j", "3d", "4g", "2h", "2a", "1c", "2b"
    ]
    #ant_list = ["1a", "1f", "5c", "4g"]

    #freqs = [950]*3 + [1600]*3 + [2250]*3
    #ant_list = ["1f"]
    freqs = [1500] * len(ant_list)
    #freqs = [750]*len(ant_list)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, True)

    #ata_control.set_freq(freqs, ant_list)
    snap_dada.set_freq_auto(freqs, ant_list)
    print("Done")
    time.sleep(30)

    source = "J0332+5434"
    ata_control.make_and_track_ephems(source, ant_list)

    ata_control.autotune(ant_list, power_level=-15)
    snap_if.tune_if_ants(ant_list)
    obs_time = 1200

    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    disable_rfi=True,
                                    npolout=1,
                                    acclen=120)
Beispiel #11
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1a",  "1c", "2a",
    #        "2h",  "4g", "1k", "5c"]

    # 4g and 1h for GNURADIO
    #ant_list = ["1a", "1f", "1c", "1h", "2a",  "1k", "5c", "4g"]
    #freqs = [950, 950, 1600, 1600, 1600, 1600, 950, 950]

    # LO b
    #sub1  = ["1f", "5c"]
    #freq1 = [950]

    # LO c
    #sub2  = ["2h", "1k", "1h"]
    #freq2 = [1300]

    # LO a
    #sub3  = ["1c", "2a", "4j"]
    #freq3 = [1650]

    #ant_list = sub1 + sub2 + sub3
    #freqs = freq1*len(sub1) + freq2*len(sub2) + freq3*len(sub3)

    #ant_list = ["1f", "5c", "1a",    "1c", "2a", "4j",    "2h", "1k", "1h"]
    #freqs = [950]*3 + [1600]*3 + [2250]*3

    ant_list = ["1f", "5c", "1a", "1c", "2a", "4j", "2h", "1k", "1h"]
    freqs = [950] * 3 + [1600] * 3 + [2250] * 3

    #ant_list = ["1f", "2a", "1k", "5c"]
    #freqs = [950, 1600, 1600, 950]

    snap_dada.set_freq_auto(freqs, ant_list)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, True)

    source = "J1935+1616"
    ata_control.make_and_track_ephems(source, ant_list)

    ata_control.autotune(ant_list)
    snap_if.tune_if_ants(ant_list)
    utc = snap_dada.start_recording(ant_list,
                                    600,
                                    npolout=1,
                                    acclen=120,
                                    disable_rfi=True)

    source = "J1934+2153"
    ata_control.make_and_track_ephems(source, ant_list)

    obs_time = 1200
    nhours = 3

    for i in range(2):
        for i in range(int(nhours * 3)):
            snap_if.tune_if_ants(ant_list)
            utc = snap_dada.start_recording(ant_list,
                                            obs_time,
                                            npolout=1,
                                            acclen=120,
                                            disable_rfi=True)
            snap_dada.mark_obs_for_heimdall(utc)
        print("Now sleeping for 20 minutes")
        time.sleep(1200)
Beispiel #12
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # casa observation
    az_offset = 20.
    el_offset = 0.

    ant_list = [
        "1a", "1f", "1c", "2a", "2b", "2h", "3c", "4g", "1k", "5c", "1h", "4j"
    ]
    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, False)

    obs_time = 30
    n_on_off = 1

    source = "casa"
    ata_control.create_ephems2(source, az_offset, el_offset)

    ata_control.point_ants2(source, "off", ant_list)
    ata_control.autotune(ant_list)

    #freqs = np.arange(1200, 9500, 350)
    #freqs = np.arange(1200, 11200, 350)
    #freqs = np.arange(1200, 1900, 350)
    #freqs = np.arange(2250, 11200, 550)
    freqs = [3500, 4500, 5500, 6500, 7500]

    snap_dada.set_freq_auto([freqs[0]] * len(ant_list), ant_list)
    time.sleep(30)
    snap_if.tune_if_ants(ant_list)

    utcs_all = []
    for ifreq, freq in enumerate(freqs):
        utcs_this_freq = []
        if ifreq != 0:
            snap_dada.set_freq_auto([freq] * len(ant_list), ant_list)
            snap_if.tune_if_ants(ant_list)

        for i in range(n_on_off):
            # record on
            ata_control.point_ants2(source, "on", ant_list)

            utc = snap_dada.start_recording(ant_list,
                                            obs_time,
                                            npolout=2,
                                            acclen=120 * 16,
                                            disable_rfi=True)

            utcs_this_freq.append(utc)
            os.system("killall ata_udpdb")

            #record off
            ata_control.point_ants2(source, "off", ant_list)

            utc = snap_dada.start_recording(ant_list,
                                            obs_time,
                                            npolout=2,
                                            acclen=120 * 16,
                                            disable_rfi=True)

            utcs_this_freq.append(utc)
            os.system("killall ata_udpdb")

        utcs_all.append(utcs_this_freq)

    initial_utc = utcs_all[0][0]

    os.system("mkdir /mnt/datax-netStorage-40G/calibration/" + initial_utc)
    for freq, utcs in zip(freqs, utcs_all):
        os.system("mkdir /mnt/datax-netStorage-40G/calibration/%s/freq_%i" %
                  (initial_utc, freq))
        for utc in utcs:
            os.system(
                "mv /mnt/buf0/obs/%s /mnt/datax-netStorage-40G/calibration/%s/freq_%i"
                % (utc, initial_utc, freq))

    os.system(
        "/home/obsuser/scripts/fil2csv.py /mnt/datax-netStorage-40G/calibration/%s/*/*/*/*.fil"
        % (initial_utc))

    o = open("/mnt/datax-netStorage-40G/calibration/obs.dat", "a")
    o.write("%s %s %i\n" % (initial_utc, source, n_on_off))
    o.close()
Beispiel #13
0
def main():
    logger = logger_defaults.getProgramLogger("observe", loglevel=logging.INFO)

    # pulsar observation
    #ant_list = ["1a",  "1c", "2a",
    #        "2h",  "4g", "1k", "5c"]

    # 4g and 1h for GNURADIO
    #ant_list = ["1a", "1f", "1c", "1h", "2a",  "1k", "5c", "4g"]
    #freqs = [950, 950, 1600, 1600, 1600, 1600, 950, 950]

    # LO b
    #sub1  = ["1f", "5c"]
    #freq1 = [950]

    # LO c
    #sub2  = ["2h", "1k", "1h"]
    #freq2 = [1300]

    # LO a
    #sub3  = ["1c", "2a", "4j"]
    #freq3 = [1650]

    #ant_list = sub1 + sub2 + sub3
    #freqs = freq1*len(sub1) + freq2*len(sub2) + freq3*len(sub3)

    #ant_list = ["1f", "5c", "1a",    "1c", "2a", "4j",    "2h", "1k", "1h"]
    #freqs = [950]*3 + [1600]*3 + [2250]*3

    #ant_list = ["1a", "1k", "5c", "1h", "4j", "3d", "4g", "2h", "2a", "1c", "2b"]
    ant_list = [
        "1a", "1f", "1c", "2a", "2h", "3d", "1k", "5c", "2b", "4g", "4j"
    ]
    freqs = [1500] * len(ant_list)

    #ant_list = ["1f", "2a", "1k", "5c"]
    #freqs = [950, 1600, 1600, 950]

    snap_dada.set_freq_auto(freqs, ant_list)

    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas, ant_list, True)

    #source = "J1935+1616"
    #ata_control.make_and_track_ephems(source, ant_list)

    #ata_control.autotune(ant_list)
    #snap_if.tune_if_ants(ant_list)
    #utc = snap_dada.start_recording(ant_list, 600,
    #                    npolout=1, acclen=120, disable_rfi=True)

    source = "J0534+2200"
    ata_control.make_and_track_ephems(source, ant_list)
    ata_control.autotune(ant_list, power_level=-15)

    obs_time = 1200

    snap_if.tune_if_ants(ant_list)
    utc = snap_dada.start_recording(ant_list,
                                    obs_time,
                                    npolout=1,
                                    acclen=120,
                                    disable_rfi=True)
    snap_dada.mark_obs_for_heimdall(utc)
    Path('/mnt/buf0/obs/%s/obs.sumall' % utc).touch()
Beispiel #14
0
def main():
    logger = logger_defaults.getProgramLogger("observe", 
            loglevel=logging.INFO)

    # moon observation
    az_offset = 20
    el_offset = 0

    #ant_list = ["1a", "1f", "1c", "2a", "2b", "2h",
    #        "3c", "4g", "1k", "5c", "1h", "4j"]
    ant_list = ["1c", "2a", "2b", "2h",
            "3c", "4g", "1k", "1h", "4j"]
    ata_control.reserve_antennas(ant_list)
    atexit.register(ata_control.release_antennas,ant_list, False)

    obs_time = 30

    source = "virgo"
    ata_control.create_ephems2(source, az_offset, el_offset)

    ata_control.point_ants2(source, "on", ant_list)
    ata_control.autotune(ant_list)

    freqs = np.arange(1200, 10500, 350)
    #freqs = np.arange(1200, 1900, 350)

    utcs_all = []
    for freq in freqs:
        utcs_this_freq = []
        snap_dada.set_freq_auto([freq]*len(ant_list), ant_list)
        snap_if.tune_if_ants(ant_list)

        for i in range(3):
            # record on
            ata_control.point_ants2(source, "on", ant_list)

            i = 0
            while i < 3:
                try:
                    utc = snap_dada.start_recording(ant_list, obs_time, 
                            npolout=2, acclen=120*16, disable_rfi=True)
                    break
                except:
                    i += 1

            utcs_this_freq.append(utc)

            #record off
            ata_control.point_ants2(source, "off", ant_list)

            i = 0
            while i < 3:
                try:
                    utc = snap_dada.start_recording(ant_list, obs_time, 
                            npolout=2, acclen=120*16, disable_rfi=True)
                    break
                except:
                    i += 1

            utcs_this_freq.append(utc)

        utcs_all.append(utcs_this_freq)

    initial_utc = utcs_all[0][0]

    os.system("mkdir /mnt/datax-netStorage-40G/calibration/"+initial_utc)
    for freq, utcs in zip(freqs, utcs_all):
        os.system("mkdir /mnt/datax-netStorage-40G/calibration/%s/freq_%i"
                %(initial_utc, freq))
        for utc in utcs:
            os.system("mv /mnt/buf0/obs/%s /mnt/datax-netStorage-40G/calibration/%s/freq_%i"
                    %(utc, initial_utc, freq))