casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes
parallel.pimager.pimager Class Reference

List of all members.

Public Member Functions

def __init__
def __del__
def setupcommonparams
def pcontmt
def combineimages
def pcont
def pcube_try
def pcube_driver
def pcube

Static Public Member Functions

def maxouterpsf
def averimages
def weightedaverimages
def findchansel
def findchanselcont
def findchanselold
def copyimage
def regridimage

Public Attributes

 msinfo
 engineinfo
 spw
 field
 phasecenter
 ftmachine
 wprojplanes
 facets
 imsize
 cell
 weight
 continue clean or not
 robust
 stokes
 visinmem
 numthreads
 gain
 npixels
 uvtaper
 outertaper
 timerange
 uvrange
 baselines
 scan
 observation
 pbcorr
 minpb
 cyclefactor
 c
 timrange

Static Public Attributes

float init
tuple elim
 OR the mask and the fluximage into the mask.
tuple sumweight
 newthresh
tuple residstat
tuple maxresid
tuple psfoutermax
tuple oldthresh
tuple newthresh
tuple needclean
 no need to do this in last major cycle
 donemaj
tuple elniter
string rundecon
 over
tuple over
tuple retval
list niterpercycle
list maxresid
tuple imminmax
 incremental added to total
string restored
tuple time2
tuple myim
 Clean up.

Detailed Description

Definition at line 17 of file pimager.py.


Constructor & Destructor Documentation

def parallel.pimager.pimager.__init__ (   self,
  cluster = '' 
)

Definition at line 18 of file pimager.py.

Definition at line 52 of file pimager.py.


Member Function Documentation

def parallel.pimager.pimager.averimages (   outimage = 'outimage',
  inimages = [] 
) [static]

Definition at line 85 of file pimager.py.

def parallel.pimager.pimager.combineimages (   self,
  rootnames = [],
  nterms = 2,
  outputrootname = '' 
)
def parallel.pimager.pimager.copyimage (   inimage = '',
  outimage = '',
  init = False,
  initval = 0.0 
) [static]
def parallel.pimager.pimager.findchansel (   msname = '',
  spw = '*',
  field = '*',
  numpartition = 1,
  freqrange = [0,
  e12 
) [static]

Definition at line 134 of file pimager.py.

References taskinit.gentools().

Referenced by parallel.pimager.pimager.pcont(), and parallel.pimager.pimager.pcontmt().

def parallel.pimager.pimager.findchanselcont (   msname = '',
  spwids = [],
  numpartition = 1,
  beginfreq = 0.0,
  endfreq = 1e12,
  freqrange = [0,
  e12 
) [static]

Definition at line 216 of file pimager.py.

References nf_regression.append, and backend_demo.pop.

def parallel.pimager.pimager.findchanselold (   msname = '',
  spwids = [],
  numpartition = 1,
  beginfreq = 0.0,
  endfreq = 1e12,
  continuum = True 
) [static]

Definition at line 324 of file pimager.py.

References nf_regression.append, and backend_demo.pop.

def parallel.pimager.pimager.maxouterpsf (   psfim = '',
  image = '' 
) [static]
def parallel.pimager.pimager.pcont (   self,
  msname = None,
  imagename = None,
  imsize = [1000,
  pixsize = ['1arcsec',
  arcsec,
  phasecenter = '',
  field = '',
  spw = '*',
  stokes = 'I',
  ftmachine = 'ft',
  wprojplanes = 128,
  facets = 1,
  hostnames = '',
  numcpuperhost = 1,
  majorcycles = -1,
  cyclefactor = 1.5,
  niter = 1000,
  npercycle = 100,
  gain = 0.1,
  threshold = '0.0mJy',
  alg = 'clark',
  scales = [0],
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  uvtaper = False,
  outertaper = [],
  timerange = '',
  uvrange = '',
  baselines = '',
  scan = '',
  observation = '',
  pbcorr = False,
  minpb = 0.2,
  contclean = False,
  visinmem = False,
  interactive = False,
  maskimage = 'lala.mask',
  numthreads = 1,
  savemodel = False,
  painc = 360.,
  pblimit = 0.1,
  dopbcorr = True,
  applyoffsets = False,
  cfcache = 'cfcache.dir',
  epjtablename = '' 
)
msname= measurementset
imagename = image
imsize = list of 2 numbers  [nx,ny] defining image size in x and y
pixsize = list of 2 quantities   ['sizex', 'sizey'] defining the pixel size e.g  ['1arcsec', '1arcsec']
phasecenter = an integer or a direction string   integer is fieldindex or direction e.g  'J2000 19h30m00 -30d00m00'
field = field selection string ...msselection style
spw = spw selection string ...msselection style
stokes= string e.g 'I', 'IV'
ftmachine= the ftmachine to use ...'ft', 'wproject' etc
wprojplanes is an interger that is valid only of ftmachine is 'wproject', 
facets= integer do split image facet, 
hostnames= list of strings ..empty string mean localhost
numcpuperhos = integer ...number of processes to launch on each host
majorcycles= integer number of CS major cycles to do, 
cyclefactor= if majorcycles=-1. This determines number of majorcycles
niter= integer ...total number of clean iteration 
threshold=quantity ...residual peak at which to stop deconvolving
alg= string  possibilities are 'clark', 'hogbom', 'msclean'
weight= string e.g 'natural', 'briggs' or 'radial'
robust= float  valid for 'briggs' only  e.g 0,0
 
scales = scales to use when using alg='msclean'
contclean = boolean ...if False the imagename.model is deleted if its on 
disk otherwise clean will continue from previous run
visinmem = load visibility in memory for major cycles...make sure totalmemory  available to all processes is more than the MS size
interactive boolean ...get a viewer to draw mask on
maskimage  a prior mask image to limit clean search
numthreads  number of threads to use in each engine
savemodel   when True the model is saved in the MS header for selfcal
painc = Parallactic angle increment in degrees after which a new convolution function is computed (default=360.0deg)
cfcache = The disk cache directory for convolution functions
pblimit = The fraction of the peak of the PB to which the PB corrections are applied (default=0.1)
dopbcorr = If true, correct for PB in the major cycles as well
applyoffsets = If true, apply antenna pointing offsets from the pointing table given by epjtablename 
epjtablename = Table containing antenna pointing offsets

Definition at line 840 of file pimager.py.

References parallel.pimager.pimager.c, parallel.pimager.pimager.copyimage(), parallel.pimager.pimager.findchansel(), casapy.fullpath, parallel.pimager.pimager.regridimage(), parallel.pimager.pimager.setupcommonparams(), and parallel.pimager.pimager.weightedaverimages().

Referenced by parallel.pimager.pimager.combineimages(), and parallel.pimager.pimager.pcontmt().

def parallel.pimager.pimager.pcontmt (   self,
  msname = None,
  imagename = None,
  imsize = [1000,
  pixsize = ['1arcsec',
  arcsec,
  phasecenter = '',
  field = '',
  spw = '*',
  stokes = 'I',
  ftmachine = 'ft',
  wprojplanes = 128,
  facets = 1,
  majorcycles = -1,
  cyclefactor = 1.5,
  niter = 1000,
  npercycle = 100,
  gain = 0.1,
  threshold = '0.0mJy',
  alg = 'clark',
  scales = [0],
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  uvtaper = False,
  outertaper = [],
  timerange = '',
  uvrange = '',
  baselines = '',
  scan = '',
  observation = '',
  pbcorr = False,
  minpb = 0.2,
  contclean = False,
  visinmem = False,
  interactive = False,
  maskimage = 'lala.mask',
  numthreads = 1,
  savemodel = False,
  nterms = 2 
)
def parallel.pimager.pimager.pcube (   self,
  msname = None,
  imagename = 'elimage',
  imsize = [1000,
  pixsize = ['1arcsec',
  arcsec,
  phasecenter = '',
  field = '',
  spw = '*',
  ftmachine = 'ft',
  wprojplanes = 128,
  facets = 1,
  hostnames = '',
  numcpuperhost = 1,
  majorcycles = -1,
  cyclefactor = 1.5,
  niter = 1000,
  gain = 0.1,
  threshold = '0.0mJy',
  alg = 'clark',
  scales = [0],
  mode = 'channel',
  start = 0,
  nchan = 1,
  step = 1,
  restfreq = '',
  stokes = 'I',
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  uvtaper = False,
  outertaper = [],
  timerange = '',
  uvrange = '',
  baselines = '',
  scan = '',
  observation = '',
  pbcorr = False,
  minpb = 0.2,
  imagetilevol = 100000,
  contclean = False,
  chanchunk = 1,
  visinmem = False,
  maskimage = '',
  numthreads = 1,
  savemodel = False,
  painc = 360.,
  pblimit = 0.1,
  dopbcorr = True,
  applyoffsets = False,
  cfcache = 'cfcache.dir',
  epjtablename = '' 
)
msname= measurementset
imagename = image
imsize = list of 2 numbers  [nx,ny] defining image size in x and y
pixsize = list of 2 quantities   ['sizex', 'sizey'] defining the pixel size e.g  ['1arcsec', '1arcsec']
phasecenter = an integer or a direction string   integer is fieldindex or direction e.g  'J2000 19h30m00 -30d00m00'
field = field selection string ...msselection style
spw = spw selection string ...msselection style
ftmachine= the ftmachine to use ...'ft', 'wproject' etc
wprojplanes is an interger that is valid only of ftmachine is 'wproject', 
facets= integer do split image facet, 
hostnames= list of strings ..empty string mean localhost
numcpuperhos = integer ...number of processes to launch on each host
majorcycles= integer number of CS major cycles to do, 
niter= integer ...total number of clean iteration 
threshold=quantity string ...residual peak at which to stop deconvolving
alg= string  possibilities are 'clark', 'hogbom', 'multiscale' and their 'mf'
scales= list of scales in pixel for multiscale clean e.g [0, 3, 10]
mode= channel definition, can be 'channel', 'frequency', 'velocity'
start = first channel in the definition spec of mode, can be int, freq or vel quantity
step = channel width specified in the definition of mode
restfreq= what 'rest frequency' to use to calculate velocity from frequency
                empty string '' implies use the first restfreq in SOURCE of ms 
weight= type of weight to apply
contclean = boolean ...if False the imagename.model is deleted if its on 
disk otherwise clean will continue from previous run
chanchunk = number of channel to process at a go per process...careful not to 
       go above total memory available
       visinmem = load visibility in memory for major cycles...make sure totalmemory  available to all processes is more than the MS size
       numthreads number of threads to use per engine while gridding
       savemodel if True save the model in the ms header for self calibration
painc = Parallactic angle increment in degrees after which a new convolution function is computed (default=360.0deg)
cfcache = The disk cache directory for convolution functions
pblimit = The fraction of the peak of the PB to which the PB corrections are applied (default=0.1)
dopbcorr = If true, correct for PB in the major cycles as well
applyoffsets = If true, apply antenna pointing offsets from the pointing table given by epjtablename 
epjtablename = Table containing antenna pointing offsets

Definition at line 1529 of file pimager.py.

References parallel.pimager.pimager.regridimage(), and parallel.pimager.pimager.setupcommonparams().

Referenced by parallel.pimager.pimager.pcube_driver().

def parallel.pimager.pimager.pcube_driver (   self,
  msname = None,
  imagename = 'elimage',
  imsize = [1000,
  pixsize = ['1arcsec',
  arcsec,
  phasecenter = '',
  field = '',
  spw = '*',
  ftmachine = 'ft',
  wprojplanes = 128,
  facets = 1,
  hostnames = '',
  numcpuperhost = 1,
  majorcycles = -1,
  cyclefactor = 1.5,
  niter = 1000,
  npercycle = 100,
  gain = 0.1,
  threshold = '0.0mJy',
  alg = 'clark',
  scales = [0],
  mode = 'channel',
  start = 0,
  nchan = 1,
  step = 1,
  restfreq = '',
  stokes = 'I',
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  uvtaper = False,
  outertaper = [],
  timerange = '',
  uvrange = '',
  baselines = '',
  scan = '',
  observation = '',
  pbcorr = False,
  minpb = 0.2,
  imagetilevol = 100000,
  contclean = False,
  chanchunk = 1,
  visinmem = False,
  maskimage = '',
  numthreads = 1,
  savemodel = False,
  painc = 360.,
  pblimit = 0.1,
  dopbcorr = True,
  applyoffsets = False,
  cfcache = 'cfcache.dir',
  epjtablename = '',
  interactive = False 
)
Drive pcube when interactive is on and depending on cyclefactor or not

Definition at line 1404 of file pimager.py.

References parallel.pimager.pimager.maxouterpsf(), and parallel.pimager.pimager.pcube().

Referenced by parallel.pimager.pimager.pcube_try().

def parallel.pimager.pimager.pcube_try (   self,
  msname = None,
  imagename = 'elimage',
  imsize = [1000,
  pixsize = ['1arcsec',
  arcsec,
  phasecenter = '',
  field = '',
  spw = '*',
  ftmachine = 'ft',
  wprojplanes = 128,
  facets = 1,
  hostnames = '',
  numcpuperhost = 1,
  majorcycles = 1,
  niter = 1000,
  gain = 0.1,
  threshold = '0.0mJy',
  alg = 'clark',
  scales = [0],
  mode = 'channel',
  start = 0,
  nchan = 1,
  step = 1,
  restfreq = '',
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  imagetilevol = 100000,
  contclean = False,
  pbcorr = False,
  chanchunk = 1,
  visinmem = False,
  maskimage = '',
  numthreads = -1,
  painc = 360.,
  pblimit = 0.1,
  dopbcorr = True,
  applyoffsets = False,
  cfcache = 'cfcache.dir',
  epjtablename = '' 
)
msname= measurementset
imagename = image
imsize = list of 2 numbers  [nx,ny] defining image size in x and y
pixsize = list of 2 quantities   ['sizex', 'sizey'] defining the pixel size e.g  ['1arcsec', '1arcsec']
phasecenter = an integer or a direction string   integer is fieldindex or direction e.g  'J2000 19h30m00 -30d00m00'
field = field selection string ...msselection style
spw = spw selection string ...msselection style
ftmachine= the ftmachine to use ...'ft', 'wproject' etc
wprojplanes is an interger that is valid only of ftmachine is 'wproject', 
facets= integer do split image facet, 
hostnames= list of strings ..empty string mean localhost
numcpuperhos = integer ...number of processes to launch on each host
majorcycles= integer number of CS major cycles to do, 
niter= integer ...total number of clean iteration 
threshold=quantity string ...residual peak at which to stop deconvolving
alg= string  possibilities are 'clark', 'hogbom', 'multiscale' and their 'mf'
scales= list of scales in pixel for multiscale clean e.g [0, 3, 10]
mode= channel definition, can be 'channel', 'frequency', 'velocity'
start = first channel in the definition spec of mode, can be int, freq or vel quantity
step = channel width specified in the definition of mode
restfreq= what 'rest frequency' to use to calculate velocity from frequency
                empty string '' implies use the first restfreq in SOURCE of ms 
weight= type of weight to apply
contclean = boolean ...if False the imagename.model is deleted if its on 
disk otherwise clean will continue from previous run
chanchunk = number of channel to process at a go per process...careful not to 
       go above total memory available
       visinmem = load visibility in memory for major cycles...make sure totalmemory  available to all processes is more than the MS size
painc = Parallactic angle increment in degrees after which a new convolution function is computed (default=360.0deg)
cfcache = The disk cache directory for convolution functions
pblimit = The fraction of the peak of the PB to which the PB corrections are applied (default=0.1)
dopbcorr = If true, correct for PB in the major cycles as well
applyoffsets = If true, apply antenna pointing offsets from the pointing table given by epjtablename 
epjtablename = Table containing antenna pointing offsets

Definition at line 1180 of file pimager.py.

References parallel.pimager.pimager.pcube_driver(), parallel.pimager.pimager.regridimage(), and parallel.pimager.pimager.setupcommonparams().

def parallel.pimager.pimager.regridimage (   outimage = '',
  inimage = '',
  templateimage = '' 
) [static]
def parallel.pimager.pimager.setupcommonparams (   self,
  spw = '*',
  field = '*',
  phasecenter = '',
  stokes = 'I',
  ftmachine = 'ft',
  wprojplanes = 64,
  facets = 1,
  imsize = [512,
  pixsize = ['1arcsec',
  arcsec,
  weight = 'natural',
  robust = 0.0,
  npixels = 0,
  gain = 0.1,
  uvtaper = False,
  outertaper = [],
  timerange = '',
  uvrange = '',
  baselines = '',
  scan = '',
  observation = '',
  visinmem = False,
  pbcorr = False,
  minpb = 0.2,
  numthreads = 1,
  cyclefactor = 1.5 
)
def parallel.pimager.pimager.weightedaverimages (   outimage = 'outimage',
  inimages = [],
  wgtimages = [] 
) [static]

Definition at line 103 of file pimager.py.

References taskinit.gentools().

Referenced by parallel.pimager.pimager.pcont().


Member Data Documentation

Definition at line 40 of file pimager.py.

Definition at line 46 of file pimager.py.

Referenced by parallel.pimager.pimager.pcont(), and parallel.pimager.pimager.pcontmt().

Definition at line 45 of file pimager.py.

Definition at line 1097 of file pimager.py.

OR the mask and the fluximage into the mask.

Definition at line 1070 of file pimager.py.

Definition at line 1102 of file pimager.py.

Definition at line 20 of file pimager.py.

Definition at line 26 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 24 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 34 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

incremental added to total

Definition at line 1120 of file pimager.py.

Definition at line 1064 of file pimager.py.

Definition at line 1086 of file pimager.py.

Definition at line 1113 of file pimager.py.

Definition at line 44 of file pimager.py.

Definition at line 19 of file pimager.py.

Clean up.

Definition at line 1159 of file pimager.py.

no need to do this in last major cycle

Definition at line 1094 of file pimager.py.

Definition at line 1082 of file pimager.py.

Definition at line 1092 of file pimager.py.

Definition at line 1112 of file pimager.py.

Definition at line 35 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 33 of file pimager.py.

Definition at line 42 of file pimager.py.

Definition at line 1089 of file pimager.py.

Definition at line 37 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 1106 of file pimager.py.

Definition at line 1109 of file pimager.py.

Definition at line 43 of file pimager.py.

Definition at line 1087 of file pimager.py.

Definition at line 1085 of file pimager.py.

Definition at line 1141 of file pimager.py.

Definition at line 1110 of file pimager.py.

Definition at line 30 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 1103 of file pimager.py.

Definition at line 1076 of file pimager.py.

Definition at line 1150 of file pimager.py.

Definition at line 38 of file pimager.py.

Definition at line 532 of file pimager.py.

Definition at line 39 of file pimager.py.

Definition at line 36 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().

Definition at line 32 of file pimager.py.

continue clean or not

do one major cycle at the end The user may want to change these in the gui Things to be done after first major cycle onlyfor mosaic stuff needs to be done here

Definition at line 29 of file pimager.py.

Referenced by task_sdgrid.sdgrid_worker.execute(), parallel.pimager.pimager.pcontmt(), and parallel.pimager.pimager.setupcommonparams().

Definition at line 25 of file pimager.py.

Referenced by parallel.pimager.pimager.setupcommonparams().


The documentation for this class was generated from the following file: