NRAO Home > CASA > CASA Task Reference Manual

0.1.118 simalma

Requires:

Synopsis
Simulation task for ALMA

Description

This task simulates ALMA observation including 12-m, ACA 7-m and total power arrays, and images and analyzes simulated data.

This task makes multiple calls to simobserve (to calculate visibilities and total power spectra), followed by gridding of total power spectra (if total power is requested), concatenation of the simulated visibilities, calls to the simanalyze task for visibility inversion and deconvolution and calculation of difference and fidelity images, and feathering of single dish and interferometric data.

These steps may not all be familiar to new users, so the simalma task runs by default in a ”dryrun” mode, in which it assesses the user’s input parameters and sky model, and prints an informational report including the required calls to other CASA tasks, both to the screen and to a text file in the project directory (defined below).

The user can modify their parameters based on the information, then either run with dryrun=False to actually call the other tasks to create the simulated data, or run the other tasks individually one at a time to better understand and control the process.

NOTE The ALMA project is refining the optimal method of combining the three types of data. If that best practice is changed after this release of CASA, the user can control the process by modifying the calls to the other CASA tasks.



Arguments





Inputs

project

root prefix for output file names

allowed:

string

Default:

sim

dryrun

dryrun=True will only produce the informative report, not run simobserve/analyze

allowed:

bool

Default:

True

skymodel

model image to observe

allowed:

string

Default:

inbright

scale surface brightness of brightest pixel e.g. ”1.2Jy/pixel”

allowed:

string

Default:

indirection

set new direction e.g. ”J2000 19h00m00 -40d00m00”

allowed:

string

Default:

incell

set new cell/pixel size e.g. ”0.1arcsec”

allowed:

string

Default:

incenter

set new frequency of center channel e.g. ”89GHz” (required even for 2D model)

allowed:

string

Default:

inwidth

set new channel width e.g. ”10MHz” (required even for 2D model)

allowed:

string

Default:

complist

componentlist to observe

allowed:

string

Default:

compwidth

bandwidth of components

allowed:

string

Default:

”8GHz”

setpointings

allowed:

bool

Default:

True

ptgfile

list of pointing positions

allowed:

string

Default:

$project.ptg.txt

integration

integration (sampling) time

allowed:

string

Default:

10s

direction

”J2000 19h00m00 -40d00m00” or ”” to center on model

allowed:

stringArray

Default:

mapsize

angular size of map or ”” to cover model

allowed:

stringArray

Default:

antennalist

antenna position files of ALMA 12m and 7m arrays

allowed:

stringArray

Default:

alma.cycle1.1.cfg aca.cycle1.cfg

hourangle

hour angle of observation center e.g. -3:00:00, or ”transit”

allowed:

string

Default:

transit

totaltime

total time of observation; vector corresponding to antennalist

allowed:

stringArray

Default:

20min 1h

tpnant

Number of total power antennas to use (0-4)

allowed:

int

Default:

0

tptime

total observation time for total power

allowed:

string

Default:

0s

pwv

Precipitable Water Vapor in mm. 0 for noise-free simulation

allowed:

double

Default:

0.5

image

image simulated data

allowed:

bool

Default:

True

imsize

output image size in pixels (x,y) or 0 to match model

allowed:

intArray

Default:

128128

imdirection

set output image direction, (otherwise center on the model)

allowed:

string

Default:

cell

cell size with units or ”” to equal model

allowed:

string

Default:

niter

maximum number of iterations (0 for dirty image)

allowed:

int

Default:

0

threshold

flux level (+units) to stop cleaning

allowed:

string

Default:

0.1mJy

graphics

display graphics at each stage to [screen—file—both—none]

allowed:

string

Default:

both

verbose

allowed:

bool

Default:

False

overwrite

overwrite files starting with $project

allowed:

bool

Default:

False

Returns
bool

Example

 
    -------------------------------  
    Parameters:  
 
    project -- root filename for all output files.  A subdirectory will be  
         created, and all created files will be placed in that subdirectory  
         including the informational report.  
 
    -------------------------------  
    skymodel -- input image (used as a model of the sky)  
       * simalma requires a CASA or fits image. If you merely have a grid of  
         numbers, you will need to write them out as fits or write a  
         CASA script to read them in and use the ia tool to create an image  
         and insert the data.  
 
       * simalma does NOT require a coordinate system in the header. If the  
         coordinate information is incomplete, missing, or you would like to  
         override it, set the appropriate "in" parameters. NOTE that setting  
         those parameters simply changes the header values, ignoring  
         any values already in the image. No regridding is performed.  
 
       * If you have a proper Coordinate System, simalma will do its best to  
         generate visibilities from that, and then create a synthesis image  
         according to the specified user parameters.  
 
       * You can manipulate an image header manually with the "imhead" task.  
 
    inbright -- peak brightness to scale the image to in Jy/pixel,  
         or "" for unchanged  
       * NOTE: "unchanged" will take the numerical values in your image  
         and assume they are in Jy/pixel, even if it says some other unit  
         in the header.  
 
    indirection -- central direction to place the sky model image,  
         or "" to use whatever is in the image already  
 
    incell -- spatial pixel size to scale the skymodel image,  
         or "" to use whatever is in the image already.  
 
    incenter -- frequency to use for the center channel (or only channel,  
         if the skymodel is 2D)  e.g. "89GHz",  
         or "" to use what is in the header.  
 
    inwidth -- width of channels to use, or "" to use what is in the image  
         should be a string representing a quantity with units e.g. "10MHz"  
       * NOTE: only works reliably with frequencies, not velocities  
       * NOTE: it is not possible to change the number of spectral planes  
         of the sky model, only to relabel them with different frequencies  
         That kind of regridding can be accomplished with the CASA toolkit.  
 
    -------------------------------  
    complist -- component list model of the sky, added to or instead of skymodel  
         see http://casaguides.nrao.edu/index.php?title=Simulation_Guide_Component_Lists_%28CASA_4.1%29  
 
    compwidth -- bandwidth of components; if simulating from components only,  
         this defines the bandwidth of the MS and output images  
 
    -------------------------------  
    setpointings -- if true, calculate a map of pointings and write ptgfile.  
       * if graphics are on, display the pointings shown on the model image  
       * observations with the ALMA 12m and ACA 7m arrays will observe a  
         region of size "mapsize" using the same hexagonal algorithm as  
         the ALMA OT, with Nyquist sampling.  
       * The total power array maps a slightly (+1 primary beam) larger area  
         than the 12m array does, to improve later image combination.  
         It samples the region with lattice grids of spacing 0.33 lambda/D.  
       * if setpointings=false, read pointings from ptgfile.  
 
    ptgfile -- a text file specifying directions in the same  
         format as the example, and optional integration times, e.g.  
         #Epoch     RA          DEC      TIME(optional)  
         J2000 23h59m28.10 -019d52m12.35 10.0  
       * if the time column is not present in the file, it will use  
         "integration" for all pointings.  
       * NOTE: at this time the file should contain only science pointings:  
         simalma will observe these until totaltime is used up.  
 
    integration --- Time interval for each integration e.g ’10s’  
       * NOTE: to simulate a "scan" longer than one integration, use  
         setpointings to generate a pointing file, and then edit the  
         file to increase the time at each point to be larger than  
         the parameter integration time.  
 
    direction -- mosaic center direction e.g ’J2000 19h00m00 -40d00m00’  
         if unset, will use the center of the skymodel image.  
       * can optionally be a list of pointings, otherwise  
       * simobserve will cover a region of size mapsize according to maptype  
 
    mapsize -- angular size of mosaic map to simulate.  
       * set to "" to cover the model image  
 
    -------------------------------  
    antennalist -- vector of ascii files containing antenna positions,  
         one for each configuration of 7m or 12m dishes.  
       * NOTE: In this task, it should be an ALMA configuration.  
       * standard arrays are found in your CASA data repository,  
         os.getenv("CASAPATH").split()[0]+"/data/alma/simmos/"  
       * a string of the form "alma;0.5arcsec" will be parsed into a  
         12m ALMA configuration - see casaguides.nrao.edu  
       * examples: [’alma.cycle2.5.cfg’,’aca.cycle2.i.cfg’]  
              [’alma.cycle1;0.3arcsec’,’alma.cycle1.1.cfg’,’aca.i.cfg’]  
 
    hourangle -- hour angle of observation e.g. ’-3h’  
       * note that if you don’t add a unit, it will assume seconds.  
 
    totaltime --- total time of observations. This should either be a scalar  
         time quantity expressed as a string e.g. ’1h’, ’3600sec’, ’10min’,  
         or a vector of such quantities, corresponding to the elements of  
         the antennalist vector, e.g. [’5min’,’20min’,’3h’].  If you  
         specify a scalar, that will be used for the highest resolution  
         12m configuration in antennalist, and any lower resolution 12m  
         configurations, any 7m configurations, and any TP configurations  
         will have observing times relative to totaltime of 0.5, 2,and 4,  
         respectively.  
    -------------------------------  
 
    tpnant -- the number of total power antennas to use in simulation.  
 
    tptime -- if tpnant>0, the user must specify the observing time for  
         total power as a CASA quantity e.g. ’4h’.  
       * NOTE: this is not broken up among multiple days -  
         a 20h track will include observations below the horizon,  
         which is probably not what is desired.  
 
    -------------------------------  
    pwv -- precipitable water vapor if constructing an atmospheric model.  
         Set 0 for noise-free simulation. When pwv>0, thermal noise is  
         applied to the simulated data.  
       * J. Pardo’s ATM library will be used to construct anatmospheric  
         profile for the ALMA site:  
         altitude 5000m, ground pressure 650mbar, relhum=20%,  
         a water layer of pwv at altitude of 2km,  
         the sky brightness temperature returned by ATM, and internally  
         tabulated receiver temperatures.  
       See the documentation of simobserve for more details.  
 
    -------------------------------  
    image -- option to invert and deconvolve the simulated measurement set(s)  
       * NOTE: interactive clean or more parameters than the subset visible  
         here are available by simply running the clean task directly.  
       * if graphics turned on, display the clean image and residual image  
       * uses Cotton-Schwab clean for single fields and Mosaic gridding  
         for multiple fields (with Clark PSF calculation in minor cycles).  
 
    imsize -- image size in spatial pixels (x,y)  
       0 or -1 will use the model image size; example: imsize=[500,500]  
 
    imdirection -- phase center for synthesized image.  default is to  
       center on the sky model.  
 
    cell -- cell size e.g ’10arcsec’.  "" defaults to the skymodel cell  
 
    niter -- number of clean/deconvolution iterations, 0 for no cleaning  
 
    threshold -- flux level to stop cleaning  
    -------------------------------  
    graphics -- view plots on the screen, saved to file, both, or neither  
    verbose -- print extra information to the logger and terminal  
    overwrite -- overwrite existing files in the project subdirectory  
    -------------------------------  
 
    Please see the documents of simobserve and simanalyze for  
    the list of outputs produced.  


More information about CASA may be found at the CASA web page

Copyright © 2016 Associated Universities Inc., Washington, D.C.

This code is available under the terms of the GNU General Public Lincense


Home | Contact Us | Directories | Site Map | Help | Privacy Policy | Search