Cmd File Generator: Difference between revisions

From Advanced Labs Wiki
Jump to navigation Jump to search
(Created page with '<pre> time = 180 #integration in seconds pointings = ['G10', 'G20', 'G30', 'G40', 'G50', 'G60', 'G70', 'G80', 'G90'] run_label = '15' # this is a unique identifier for this datas…')
 
No edit summary
 
Line 1: Line 1:
This generates the long set of observations on the galactic plane. You still need to add a reference observation for background subtraction if you don't have one already. Also don't forget to add a short record command at the beginning given the bug that prevents the first data file written from having data.
<pre>
<pre>
time = 180 #integration in seconds
time = 180 #integration in seconds

Latest revision as of 22:34, 21 April 2014

This generates the long set of observations on the galactic plane. You still need to add a reference observation for background subtraction if you don't have one already. Also don't forget to add a short record command at the beginning given the bug that prevents the first data file written from having data.

time = 180 #integration in seconds
pointings = ['G10', 'G20', 'G30', 'G40', 'G50', 'G60', 'G70', 'G80', 'G90']
run_label = '15' # this is a unique identifier for this dataset. 
                 #A serial#, date, or...
ints_per_point = 5 # number of integrations per pointing
directory = '/home/student/data/AdvLab' #directory where data is stored

f = file('cmd.txt','w')
for p in pointings:
    f.write(': %s\n' % p)
    for i in range(ints_per_point):
        f.write(': clearint\n')
        f.write(': record %s/%s_%s_%02d.rad\n' % (directory, p, run_label, i))
        f.write(':%d\n' % time)
        f.write(': roff\n')

f.close()