Beispiel #1
0
def selfcal(vis, model):
    selfcal = mirexec.TaskSelfCal()
    selfcal.vis = vis
    selfcal.model = model
    selfcal.options = 'amplitude'
    tout = selfcal.snarf()
    acos.taskout(selfcal, tout, 'selfcal.txt')
Beispiel #2
0
def selfcal(settings):
    '''
    selfcal(settings)
        Utility for running selfcal on one more visibility files. 
        This cd's to your working directory and selfcals the visibility as defined by the vis and pointing
        keywords in the selfcal section of your settings file. 
    '''
    selfcal = mirexec.TaskSelfCal()
    params = settings.get('selfcal')
    for p in params.__dict__:
        setattr(selfcal, p, params[p])
    if params.clip != '':
        selfcal.clip = params.clip
    os.chdir(settings.get('data', 'working'))
    print "SELFCAL: ", settings.get('selfcal', 'vis')
    if type(settings.get('selfcal', 'vis')) != str:
        for i in range(0, len(settings.get('selfcal', 'vis'))):
            selfcal.vis = settings.get('selfcal',
                                       'pointing') + '/' + settings.get(
                                           'selfcal', 'vis')[i]
            print "SELFCAL on ", selfcal.vis
            selfcal.model = settings.get('selfcal',
                                         'pointing') + '/' + settings.get(
                                             'selfcal', 'model')[i]
            tout = selfcal.snarf()
    else:
        selfcal.vis = settings.get('selfcal', 'pointing') + '/' + settings.get(
            'selfcal', 'vis')
        print "SELFCAL on ", selfcal.vis
        selfcal.model = settings.get(
            'selfcal', 'pointing') + '/' + settings.get('selfcal', 'model')
        tout = selfcal.snarf()
    print "DONE"
    return tout
Beispiel #3
0
def selfcal(vis, select, modelname, interval=1.0, so='mfs,phase'):
    selfcal = mirexec.TaskSelfCal()
    selfcal.vis = vis
    selfcal.select = select
    selfcal.model = modelname
    selfcal.options = so
    selfcal.interval = interval
    tout = selfcal.snarf()
Beispiel #4
0
def selfcal(settings, fname):
    selfcal = mirexec.TaskSelfCal()
    selfcal.vis = settings.vis
    selfcal.options = settings.selfcal_options
    selfcal.model = settings.m4s
    selfcal.interval = settings.selfcal_interval
    selfcal.select = settings.selfcal_select
    tout = selfcal.snarf()
    acos.taskout(selfcal, tout, fname)
Beispiel #5
0
def selfcal(params):
    selfcal = mirexec.TaskSelfCal()
    selfcal.vis = params.vis
    selfcal.select = params.select
    selfcal.model = params.model
    selfcal.options = params.sopts
    selfcal.interval = params.interval
    selfcal.line = params.line
    if params.clip != '':
        selfcal.clip = params.clip
    tout = selfcal.snarf()
    return tout
Beispiel #6
0
def selfcal(params):
	selfcal = mirexec.TaskSelfCal()