casa
$Rev:20696$
|
00001 # 00002 # This file was generated using xslt from its XML file 00003 # 00004 # Copyright 2008, Associated Universities Inc., Washington DC 00005 # 00006 import sys 00007 import os 00008 #from casac import * 00009 import casac 00010 import string 00011 import time 00012 import inspect 00013 import gc 00014 import numpy 00015 from odict import odict 00016 from taskmanager import tm 00017 from task_sdimaging import sdimaging 00018 class sdimaging_cli_: 00019 __name__ = "sdimaging" 00020 __async__ = {} 00021 rkey = None 00022 i_am_a_casapy_task = None 00023 # The existence of the i_am_a_casapy_task attribute allows help() 00024 # (and other) to treat casapy tasks as a special case. 00025 00026 def __init__(self) : 00027 self.__bases__ = (sdimaging_cli_,) 00028 self.__doc__ = self.__call__.__doc__ 00029 00030 self.parameters={'infile':None, 'specunit':None, 'restfreq':None, 'scanlist':None, 'field':None, 'spw':None, 'antenna':None, 'stokes':None, 'gridfunction':None, 'convsupport':None, 'truncate':None, 'gwidth':None, 'jwidth':None, 'outfile':None, 'overwrite':None, 'imsize':None, 'cell':None, 'dochannelmap':None, 'nchan':None, 'start':None, 'step':None, 'phasecenter':None, 'ephemsrcname':None, 'pointingcolumn':None, 'async':None} 00031 00032 00033 def result(self, key=None): 00034 #### here we will scan the task-ids in __async__ 00035 #### and add any that have completed... 00036 if key is not None and self.__async__.has_key(key) and self.__async__[key] is not None: 00037 ret = tm.retrieve(self.__async__[key]) 00038 if ret['state'] == "done" : 00039 self.__async__[key] = None 00040 elif ret['state'] == 'crashed' : 00041 self.__async__[key] = None 00042 return ret 00043 return None 00044 00045 00046 def __call__(self, infile=None, specunit=None, restfreq=None, scanlist=None, field=None, spw=None, antenna=None, stokes=None, gridfunction=None, convsupport=None, truncate=None, gwidth=None, jwidth=None, outfile=None, overwrite=None, imsize=None, cell=None, dochannelmap=None, nchan=None, start=None, step=None, phasecenter=None, ephemsrcname=None, pointingcolumn=None, async=None): 00047 00048 """SD task: imaging for total power and spectral data 00049 Keyword arguments: 00050 infile -- name of input SD (MS) dataset 00051 specunit -- units for spectral axis 00052 options: (str) 'channel','km/s','GHz','MHz','kHz','Hz' 00053 default: 'channel' 00054 example: this will be the units for nchan, start, and step 00055 restfreq -- rest frequency 00056 default: '' (refer input data) 00057 example: 1.0e11, '100GHz' 00058 scanlist -- list of scan numbers to process 00059 default: [] (use all scans) 00060 example: [21,22,23,24] 00061 this selection is in addition to field and spw 00062 field -- field id or selection string for selecting scans by name 00063 default: -1 (all fields) 00064 example: 'FLS3a', 0 00065 this selection is in addition to scanlist and spw 00066 spw -- spectral window id 00067 default: 0 00068 example: 1 00069 this selection is in addition to scanlist and field 00070 antenna -- select data based on antenna name(s) or id(s) 00071 default: -1 (all baselines, i.e. all antenna in case of auto data) 00072 example: 0, 'DV01' 00073 stokes -- select data based on stokes or polarization type 00074 default: '' (use all polarizations) 00075 example: 'XX' 00076 gridfunction -- gridding function for imaging 00077 options: 'BOX' (Box-car), 'SF' (Spheroidal), 00078 'PB' (Primary-beam), 'GAUSS' (Gaussian), 00079 'GJINC' (Gaussian*Jinc) 00080 default: 'BOX' 00081 example: 'SF' 00082 >>> gridfunction expandable parameter: 00083 convsupport -- convolution support for 'SF' 00084 default: -1 (use default for each gridfunction) 00085 example: 3 00086 truncate -- truncattion radius of convolution kernel. 00087 effective only for 'GAUSS' and 'GJINC'. 00088 default: '-1' (use default for each gridfunction) 00089 example: 3, '20arcsec', '3pixel' 00090 gwidth -- HWHM for gaussian. Effective only for 00091 'GAUSS' and 'GJINC'. 00092 default: '-1' (use default for each gridfunction) 00093 example: 3, '20arcsec', '3pixel' 00094 jwidth -- Width of jinc function. Effective only for 00095 'GJINC'. 00096 default: '-1' (use default for each gridfunction) 00097 example: 3, '20arcsec', '3pixel' 00098 outfile -- output image name 00099 default: none 00100 example: 'mySDimage.im' 00101 overwrite -- overwrite option for outfile 00102 default: False (not overwrite) 00103 options: True, False 00104 example: if True, existing file will be overwritten 00105 imsize -- x and y image size in pixels, symmetric for single value 00106 default: [256,256] 00107 example: imsize=200 (equivalent to [200,200]) 00108 cell -- x and y cell size. default unit arcmin 00109 default: ['1.0arcmin', '1.0arcmin'] 00110 example: cell=['0.2arcmin, 0.2arcmin'] 00111 cell='0.2arcmin' (equivalent to example above) 00112 dochannelmap -- channel map image or total power image 00113 default: False (total power) 00114 options: True (channel map), False 00115 >>> dochannelmap=True expandable parameters 00116 nchan -- number of spectral channel for created image 00117 default: 1 00118 example: 100 00119 start -- reference value of start channel (in units of specunit) 00120 default: 0 (0th channel if specunit='channel') 00121 example: 100 00122 step -- width of each spectral channel for created image 00123 default: 1 (width of 1 channel if specunit='channel') 00124 example: 100 00125 phasecenter -- image phase center: direction measure or fieldid 00126 default: 0 00127 example: 'J2000 13h44m00 -17d02m00', 'AZEL -123d48m29 15d41m41' 00128 ephemsrcname -- ephemeris source name for moving source 00129 default: '' 00130 if the source name in the data matches one of the known 00131 solar objects by the system, this task automatically set 00132 the source name. 00133 example: 'moon' 00134 pointingcolumn -- pointing data column to use 00135 option: 'direction', 'target', 'pointing_offset', 'source_offset', 'encoder' 00136 default: 'direction' 00137 00138 00139 DESCRIPTION: 00140 00141 Task sdimaging create image from input single-dish data. 00142 The input can be either total power and spectral data. Currently, 00143 this task directly accesses the Measurement Set data only because of 00144 the data access efficiency. So it differs from other single-dish 00145 tasks that mostly operate on the ASAP scantable data format. 00146 00147 Units of spectral axis can be specified via a parameter specunit. 00148 Allowed values for specunit are 'channel', 'GHz', 'MHz', 'kHz', 'Hz', 00149 and 'km/s'. This parameter is also used as the units of the parameter 00150 start and step that specify reference value of start channel and 00151 width of each spectral channel for channel map, respectively. 00152 The parameter nchan specifies number of channels for created image. 00153 If you set nchan as -1, the task selects existing all channels and 00154 combine those data into one channel to create continuum image. 00155 00156 You can specify field id or name directly. By default, field is set 00157 to -1 that means the task selects all fields in the data. 00158 00159 Selection of the antennas can be made by setting antennaid(s) or 00160 antenna name(s) in string (e.g. '0', 'DV01',etc.) or integer 00161 (e.g. 0). Defalut value, -1, means that the task selects data from 00162 all baseline, i.e., data from all antenna when data only contains 00163 auto-correlation. 00164 00165 The parameter gridfunction sets gridding function for imaging. 00166 Currently, the task supports 'BOX' (Box-car), 'SF' (Prolate 00167 Spheroidal Wave Function), 'GAUSS' (Gaussian), 'GJINC' (Gaussian* 00168 Jinc), where Jinc(x) = J_1(pi*x/c)/(pi*x/c) with a first order 00169 Bessel function J_1, and 'PB' (Primary Beam). For 'PB', correct 00170 antenna informations should be included in input file. 00171 00172 There are four subparameters for gridfunction: convsupport, truncate, 00173 gwidth, and jwidth. The convsupport is an integer specifying cut-off 00174 radius for 'SF' in units of pixel. By default (convsupport=-1), 00175 the cut-off radius is set to 3 pixels. The truncate is a cut-off 00176 radius for 'GAUSS' or 'GJINC'. It accepts integer, float, and 00177 string values of numeric plus unit. Allowed units are angular 00178 units such as 'deg', 'arcmin', 'arcsec', and 'pixel'. Default unit 00179 is 'pixel' so that string without unit or numerical values (integer 00180 or float) will be interpreted as radius in pixel. Default value 00181 for truncate, which is used when negative radius is set, is 3*HWHM 00182 for 'GAUSS' and radius at first null for 'GJINC'. The gwidth is 00183 the HWHM of gaussian for 'GAUSS' and 'GJINC'. Default value is 00184 sqrt(log(2)) pixel for 'GAUSS' and 2.52*sqrt(log(2)) pixel for 00185 'GJINC'. The jwidth specifies width of the jinc function (parameter 00186 'c' in the definition above). Default is 1.55 pixel. Both gwidth 00187 jwidth allows integer, float, or string of numeric plus unit. 00188 Default values for gwidth and jwidth are taken from Mangum et al. 00189 (2007). 00190 00191 """ 00192 if not hasattr(self, "__globals__") or self.__globals__ == None : 00193 self.__globals__=sys._getframe(len(inspect.stack())-1).f_globals 00194 #casac = self.__globals__['casac'] 00195 casalog = self.__globals__['casalog'] 00196 #casalog = casac.casac.logsink() 00197 self.__globals__['__last_task'] = 'sdimaging' 00198 self.__globals__['taskname'] = 'sdimaging' 00199 ### 00200 self.__globals__['update_params'](func=self.__globals__['taskname'],printtext=False,ipython_globals=self.__globals__) 00201 ### 00202 ### 00203 #Handle globals or user over-ride of arguments 00204 # 00205 function_signature_defaults=dict(zip(self.__call__.func_code.co_varnames,self.__call__.func_defaults)) 00206 useLocalDefaults = False 00207 00208 for item in function_signature_defaults.iteritems(): 00209 key,val = item 00210 keyVal = eval(key) 00211 if (keyVal == None): 00212 #user hasn't set it - use global/default 00213 pass 00214 else: 00215 #user has set it - use over-ride 00216 if (key != 'self') : 00217 useLocalDefaults = True 00218 00219 myparams = {} 00220 if useLocalDefaults : 00221 for item in function_signature_defaults.iteritems(): 00222 key,val = item 00223 keyVal = eval(key) 00224 exec('myparams[key] = keyVal') 00225 self.parameters[key] = keyVal 00226 if (keyVal == None): 00227 exec('myparams[key] = '+ key + ' = self.itsdefault(key)') 00228 keyVal = eval(key) 00229 if(type(keyVal) == dict) : 00230 if len(keyVal) > 0 : 00231 exec('myparams[key] = ' + key + ' = keyVal[len(keyVal)-1][\'value\']') 00232 else : 00233 exec('myparams[key] = ' + key + ' = {}') 00234 00235 else : 00236 async = self.parameters['async'] 00237 myparams['infile'] = infile = self.parameters['infile'] 00238 myparams['specunit'] = specunit = self.parameters['specunit'] 00239 myparams['restfreq'] = restfreq = self.parameters['restfreq'] 00240 myparams['scanlist'] = scanlist = self.parameters['scanlist'] 00241 myparams['field'] = field = self.parameters['field'] 00242 myparams['spw'] = spw = self.parameters['spw'] 00243 myparams['antenna'] = antenna = self.parameters['antenna'] 00244 myparams['stokes'] = stokes = self.parameters['stokes'] 00245 myparams['gridfunction'] = gridfunction = self.parameters['gridfunction'] 00246 myparams['convsupport'] = convsupport = self.parameters['convsupport'] 00247 myparams['truncate'] = truncate = self.parameters['truncate'] 00248 myparams['gwidth'] = gwidth = self.parameters['gwidth'] 00249 myparams['jwidth'] = jwidth = self.parameters['jwidth'] 00250 myparams['outfile'] = outfile = self.parameters['outfile'] 00251 myparams['overwrite'] = overwrite = self.parameters['overwrite'] 00252 myparams['imsize'] = imsize = self.parameters['imsize'] 00253 myparams['cell'] = cell = self.parameters['cell'] 00254 myparams['dochannelmap'] = dochannelmap = self.parameters['dochannelmap'] 00255 myparams['nchan'] = nchan = self.parameters['nchan'] 00256 myparams['start'] = start = self.parameters['start'] 00257 myparams['step'] = step = self.parameters['step'] 00258 myparams['phasecenter'] = phasecenter = self.parameters['phasecenter'] 00259 myparams['ephemsrcname'] = ephemsrcname = self.parameters['ephemsrcname'] 00260 myparams['pointingcolumn'] = pointingcolumn = self.parameters['pointingcolumn'] 00261 00262 if type(scanlist)==int: scanlist=[scanlist] 00263 if type(imsize)==int: imsize=[imsize] 00264 if type(cell)==float: cell=[cell] 00265 00266 result = None 00267 00268 # 00269 # The following is work around to avoid a bug with current python translation 00270 # 00271 mytmp = {} 00272 00273 mytmp['infile'] = infile 00274 mytmp['specunit'] = specunit 00275 mytmp['restfreq'] = restfreq 00276 mytmp['scanlist'] = scanlist 00277 mytmp['field'] = field 00278 mytmp['spw'] = spw 00279 mytmp['antenna'] = antenna 00280 mytmp['stokes'] = stokes 00281 mytmp['gridfunction'] = gridfunction 00282 mytmp['convsupport'] = convsupport 00283 mytmp['truncate'] = truncate 00284 mytmp['gwidth'] = gwidth 00285 mytmp['jwidth'] = jwidth 00286 mytmp['outfile'] = outfile 00287 mytmp['overwrite'] = overwrite 00288 mytmp['imsize'] = imsize 00289 if type(cell) == str : 00290 mytmp['cell'] = casac.casac.qa.quantity(cell) 00291 else : 00292 mytmp['cell'] = cell 00293 mytmp['dochannelmap'] = dochannelmap 00294 mytmp['nchan'] = nchan 00295 mytmp['start'] = start 00296 mytmp['step'] = step 00297 mytmp['phasecenter'] = phasecenter 00298 mytmp['ephemsrcname'] = ephemsrcname 00299 mytmp['pointingcolumn'] = pointingcolumn 00300 pathname='file:///'+os.environ.get('CASAPATH').split()[0]+'/share/xml/' 00301 trec = casac.casac.utils().torecord(pathname+'sdimaging.xml') 00302 00303 casalog.origin('sdimaging') 00304 try : 00305 #if not trec.has_key('sdimaging') or not casac.casac.utils().verify(mytmp, trec['sdimaging']) : 00306 #return False 00307 00308 casac.casac.utils().verify(mytmp, trec['sdimaging'], True) 00309 scriptstr=[''] 00310 saveinputs = self.__globals__['saveinputs'] 00311 saveinputs('sdimaging', 'sdimaging.last', myparams, self.__globals__,scriptstr=scriptstr) 00312 if async : 00313 count = 0 00314 keybase = time.strftime("%y%m%d.%H%M%S") 00315 key = keybase + "_" + str(count) 00316 while self.__async__.has_key(key) : 00317 count += 1 00318 key = keybase + "_" + str(count) 00319 result = tm.execute('sdimaging', infile, specunit, restfreq, scanlist, field, spw, antenna, stokes, gridfunction, convsupport, truncate, gwidth, jwidth, outfile, overwrite, imsize, cell, dochannelmap, nchan, start, step, phasecenter, ephemsrcname, pointingcolumn) 00320 print "Use: " 00321 print " tm.retrieve(return_value) # to retrieve the status" 00322 print 00323 self.rkey = key 00324 self.__async__[key] = result 00325 else : 00326 tname = 'sdimaging' 00327 spaces = ' '*(18-len(tname)) 00328 casalog.post('\n##########################################'+ 00329 '\n##### Begin Task: ' + tname + spaces + ' #####') 00330 casalog.post(scriptstr[1][1:]+'\n', 'INFO') 00331 result = sdimaging(infile, specunit, restfreq, scanlist, field, spw, antenna, stokes, gridfunction, convsupport, truncate, gwidth, jwidth, outfile, overwrite, imsize, cell, dochannelmap, nchan, start, step, phasecenter, ephemsrcname, pointingcolumn) 00332 casalog.post('##### End Task: ' + tname + ' ' + spaces + ' #####'+ 00333 '\n##########################################') 00334 00335 except Exception, instance: 00336 if(self.__globals__.has_key('__rethrow_casa_exceptions') and self.__globals__['__rethrow_casa_exceptions']) : 00337 raise 00338 else : 00339 #print '**** Error **** ',instance 00340 tname = 'sdimaging' 00341 casalog.post('An error occurred running task '+tname+'.', 'ERROR') 00342 pass 00343 00344 gc.collect() 00345 return result 00346 # 00347 # 00348 # 00349 def paramgui(self, useGlobals=True, ipython_globals=None): 00350 """ 00351 Opens a parameter GUI for this task. If useGlobals is true, then any relevant global parameter settings are used. 00352 """ 00353 import paramgui 00354 if not hasattr(self, "__globals__") or self.__globals__ == None : 00355 self.__globals__=sys._getframe(len(inspect.stack())-1).f_globals 00356 00357 if useGlobals: 00358 if ipython_globals == None: 00359 myf=self.__globals__ 00360 else: 00361 myf=ipython_globals 00362 00363 paramgui.setGlobals(myf) 00364 else: 00365 paramgui.setGlobals({}) 00366 00367 paramgui.runTask('sdimaging', myf['_ip']) 00368 paramgui.setGlobals({}) 00369 00370 # 00371 # 00372 # 00373 def defaults(self, param=None, ipython_globals=None, paramvalue=None, subparam=None): 00374 if not hasattr(self, "__globals__") or self.__globals__ == None : 00375 self.__globals__=sys._getframe(len(inspect.stack())-1).f_globals 00376 if ipython_globals == None: 00377 myf=self.__globals__ 00378 else: 00379 myf=ipython_globals 00380 00381 a = odict() 00382 a['infile'] = '' 00383 a['specunit'] = '' 00384 a['restfreq'] = '' 00385 a['scanlist'] = [] 00386 a['field'] = -1 00387 a['spw'] = 0 00388 a['antenna'] = -1 00389 a['stokes'] = '' 00390 a['gridfunction'] = 'BOX' 00391 a['outfile'] = '' 00392 a['overwrite'] = False 00393 a['imsize'] = [256, 256] 00394 a['cell'] = ['1.0arcmin', '1.0arcmin'] 00395 a['dochannelmap'] = False 00396 a['phasecenter'] = '' 00397 a['ephemsrcname'] = '' 00398 a['pointingcolumn'] = 'direction' 00399 00400 a['async']=False 00401 a['dochannelmap'] = { 00402 0:{'value':False}, 00403 1:odict([{'value':True}, {'nchan':1}, {'start':0}, {'step':1}])} 00404 a['gridfunction'] = { 00405 0:{'value':'BOX'}, 00406 1:{'value':'box'}, 00407 2:odict([{'value':'SF'}, {'convsupport':-1}]), 00408 3:odict([{'value':'sf'}, {'convsupport':-1}]), 00409 4:{'value':'PB'}, 00410 5:{'value':'pb'}, 00411 6:odict([{'value':'GAUSS'}, {'truncate':-1}, {'gwidth':-1}]), 00412 7:odict([{'value':'gauss'}, {'truncate':-1}, {'gwidth':-1}]), 00413 8:odict([{'value':'GJINC'}, {'truncate':-1}, {'gwidth':-1}, {'jwidth':-1}]), 00414 9:odict([{'value':'gjinc'}, {'truncate':-1}, {'gwidth':-1}, {'jwidth':-1}])} 00415 00416 ### This function sets the default values but also will return the list of 00417 ### parameters or the default value of a given parameter 00418 if(param == None): 00419 myf['__set_default_parameters'](a) 00420 elif(param == 'paramkeys'): 00421 return a.keys() 00422 else: 00423 if(paramvalue==None and subparam==None): 00424 if(a.has_key(param)): 00425 return a[param] 00426 else: 00427 return self.itsdefault(param) 00428 else: 00429 retval=a[param] 00430 if(type(a[param])==dict): 00431 for k in range(len(a[param])): 00432 valornotval='value' 00433 if(a[param][k].has_key('notvalue')): 00434 valornotval='notvalue' 00435 if((a[param][k][valornotval])==paramvalue): 00436 retval=a[param][k].copy() 00437 retval.pop(valornotval) 00438 if(subparam != None): 00439 if(retval.has_key(subparam)): 00440 retval=retval[subparam] 00441 else: 00442 retval=self.itsdefault(subparam) 00443 else: 00444 retval=self.itsdefault(subparam) 00445 return retval 00446 00447 00448 # 00449 # 00450 def check_params(self, param=None, value=None, ipython_globals=None): 00451 if ipython_globals == None: 00452 myf=self.__globals__ 00453 else: 00454 myf=ipython_globals 00455 # print 'param:', param, 'value:', value 00456 try : 00457 if str(type(value)) != "<type 'instance'>" : 00458 value0 = value 00459 value = myf['cu'].expandparam(param, value) 00460 matchtype = False 00461 if(type(value) == numpy.ndarray): 00462 if(type(value) == type(value0)): 00463 myf[param] = value.tolist() 00464 else: 00465 #print 'value:', value, 'value0:', value0 00466 #print 'type(value):', type(value), 'type(value0):', type(value0) 00467 myf[param] = value0 00468 if type(value0) != list : 00469 matchtype = True 00470 else : 00471 myf[param] = value 00472 value = myf['cu'].verifyparam({param:value}) 00473 if matchtype: 00474 value = False 00475 except Exception, instance: 00476 #ignore the exception and just return it unchecked 00477 myf[param] = value 00478 return value 00479 # 00480 # 00481 def description(self, key='sdimaging', subkey=None): 00482 desc={'sdimaging': 'SD task: imaging for total power and spectral data', 00483 'infile': 'name of input SD dataset(only MS is allowed for this task)', 00484 'specunit': 'units for spectral axis (channel,km/s,GHz)', 00485 'restfreq': 'rest frequency', 00486 'scanlist': 'list of scans to use (e.g. [1,2,3,4])', 00487 'field': 'string for selection by field name or id', 00488 'spw': 'spectral window id for imaging', 00489 'antenna': 'antenna name(s) or id(s)', 00490 'stokes': 'stokes or correlation name (e.g. "I", "XX")', 00491 'gridfunction': 'gridding function for imaging ("BOX","SF","PB")', 00492 'convsupport': 'convolution support for gridding', 00493 'truncate': 'truncation radius for gridding', 00494 'gwidth': 'HWHM for gaussian', 00495 'jwidth': 'c-parameter for jinc function', 00496 'outfile': 'output image name', 00497 'overwrite': 'overwrite option', 00498 'imsize': 'x and y image size in pixels, symmetric for single value', 00499 'cell': 'x and y cell size. default unit arcmin', 00500 'dochannelmap': 'True for channel map, False for total power imaging', 00501 'nchan': 'number of spectral channel for created image', 00502 'start': 'reference value of start channel (in units of specunit)', 00503 'step': 'width of each spectral channel (in units of specunit)', 00504 'phasecenter': 'Image phase center: position or field index', 00505 'ephemsrcname': 'ephemeris source name', 00506 'pointingcolumn': 'pointing data column to use', 00507 00508 'async': 'If true the taskname must be started using sdimaging(...)' 00509 } 00510 00511 # 00512 # Set subfields defaults if needed 00513 # 00514 00515 if(desc.has_key(key)) : 00516 return desc[key] 00517 00518 def itsdefault(self, paramname) : 00519 a = {} 00520 a['infile'] = '' 00521 a['specunit'] = '' 00522 a['restfreq'] = '' 00523 a['scanlist'] = [] 00524 a['field'] = -1 00525 a['spw'] = 0 00526 a['antenna'] = -1 00527 a['stokes'] = '' 00528 a['gridfunction'] = 'BOX' 00529 a['convsupport'] = -1 00530 a['truncate'] = -1 00531 a['gwidth'] = -1 00532 a['jwidth'] = -1 00533 a['outfile'] = '' 00534 a['overwrite'] = False 00535 a['imsize'] = [256, 256] 00536 a['cell'] = ['1.0arcmin', '1.0arcmin'] 00537 a['dochannelmap'] = False 00538 a['nchan'] = 1 00539 a['start'] = 0 00540 a['step'] = 1 00541 a['phasecenter'] = '' 00542 a['ephemsrcname'] = '' 00543 a['pointingcolumn'] = 'direction' 00544 00545 #a = sys._getframe(len(inspect.stack())-1).f_globals 00546 00547 if self.parameters['dochannelmap'] == True: 00548 a['nchan'] = 1 00549 a['start'] = 0 00550 a['step'] = 1 00551 00552 if self.parameters['gridfunction'] == 'SF': 00553 a['convsupport'] = -1 00554 00555 if self.parameters['gridfunction'] == 'sf': 00556 a['convsupport'] = -1 00557 00558 if self.parameters['gridfunction'] == 'GAUSS': 00559 a['truncate'] = -1 00560 a['gwidth'] = -1 00561 00562 if self.parameters['gridfunction'] == 'gauss': 00563 a['truncate'] = -1 00564 a['gwidth'] = -1 00565 00566 if self.parameters['gridfunction'] == 'GJINC': 00567 a['truncate'] = -1 00568 a['gwidth'] = -1 00569 a['jwidth'] = -1 00570 00571 if self.parameters['gridfunction'] == 'gjinc': 00572 a['truncate'] = -1 00573 a['gwidth'] = -1 00574 a['jwidth'] = -1 00575 00576 if a.has_key(paramname) : 00577 return a[paramname] 00578 sdimaging_cli = sdimaging_cli_()