Open in Colab: https://colab.research.google.com/github/casangi/casadocs/blob/0f15dab/docs/notebooks/introduction.ipynb


Release Information

These are the release notes for CASA 6.6. Changes compared to the CASA 6.5 release are listed below.


Highlights

  • Mac ARM: native CASA builds for Mac ARM now available (but do not include the Viewer). (CASA 6.6.4)

  • CASA config: addition of a new casaconfig package; external data no longer packaged with monolithic CASA. (CASA 6.6.4)

  • tclean: new mtmfs-via-cube imaging mode (specmode=’mvc’) with accurate wideband primary beam correction. (CASA 6.6.4)

  • polfromgain: new parameter minpacov to specify a minimum parallactic coverage threshold. (CASA 6.6.4)

  • getephemtable: posrefsys keyword changed to ICRS, and support added for non-alphanumeric characters. (CASA 6.6.4)

  • setjy: usescratch now defaults to True, and False is no longer allowed with Butler-JPL-Horizons. (CASA 6.6.4)

  • fixplanets: removed functionality to attach JPL-Horizons ephemeris data in MIME format (use new task getephemtable). (CASA 6.6.4)

  • getantposalma: new task to query ALMA antenna position web service and return list of antenna ITRF positions. (CASA 6.6.4)

  • tsdimaging: performance for ALMA Solar TP imaging improved about 30%. (CASA 6.6.4)

  • ASDM: ASDM code has been synced with master copy generated by ALMA builds. (CASA 6.6.4)

  • pip-wheels: Pip-wheels for Python 3.10 (Google Colab) are now available (CASA 6.6.0). A compatibility with matplotlib was resolved for the Python 3.10 wheels. (CASA 6.6.3)

  • getephemtable: new task to retrieve JPL-Horizons ephemeris data. (CASA 6.6.3)

  • getcalmodvla: new task to to retrieve flux calibrator brightness distributions and create component lists. (CASA 6.6.3)

  • gencal: new parameter ant_pos_time to limit period for which antenna position corrections are included. (CASA 6.6.3)

  • tec_maps: now consistent with new file-naming convention on remote CDDIS server. (CASA 6.6.3)

  • tclean: algorithmic improvements to the ASP deconvolver for large spread of spatial scales. (CASA 6.6.3)

  • tclean/sdintimaging: now sorts input list of MSes in chronological order. (CASA 6.6.3)

  • tclean/sdintimaging: now checks for mismatches in column states when given multiple input MSs. (CASA 6.6.3)

  • simulator: simutil now performs case sensitive comparisons for ‘known observatories’. (CASA 6.6.3)

  • plotms: correlation selection now supports standard Stokes parameters and polarization quantities. (CASA 6.6.3)

  • plotms: now better specifies values in the legend when coloraxis is set. (CASA 6.6.0)

  • plotms: parameter colorizeoverlay was added to better specify overlay colors. (CASA 6.6.0)

  • installation: a test script was added so users can test their CASA installation. (CASA 6.6.0)

  • telemetry/crash reporter: functionality was deprecated and removed. (CASA 6.6.0)

  • deconvolve: mtmfs was enabled as an algorithm option. (CASA 6.6.0)

  • defintent: new task to modify the scan intents of a measurement set. (CASA 6.6.0)

  • tclean/deconvolve: return dictionaries were added for niter=0 calls. (CASA 6.6.0)

  • image tool: fitsheader function added to return FITS header as Python dictionary. (CASA 6.6.0)

  • sdimaging: new parameter convertfirst, to reduce the number of direction conversions. (CASA 6.6.0)

  • Multiple MS input: clarifications were added to the CASA logger on how CASA handles the input of multiple MSs. (CASA 6.6.0)

Release Notes

Installation and operation

  • casaconfig: Monolithic CASA distributions no longer include the required external data, and modular packages (e.g. casatools, casatasks) no longer obtain this data from the casadata python package. Instead, a new casaconfig package is provided to handle configuration settings and to retrieve and update the external data. Most users upgrading their own CASA installation will need to perform a one-time setup of casaconfig before starting CASA. More information is available in the External Data Section. (CASA 6.6.4)

  • ASDM: ASDM code has been synced with master copy generated by ALMA builds. This change includes toggling the default output format to binary (from XML) for the following Cal* tables: CalAmpli, CalAppPhase, CalBandpass, CalCurve, CalData, CalDelay, CalFlux, CalFocusModel, CalFocus, CalGain, CalHolography, CalPointingModel, CalPointing, CalPosition, CalPrimaryBeam, CalReduction, CalSeeing. This change also includes fixing a bug in how EntityRef and Complex types were read from tables stored in binary format. (CASA 6.6.4)

  • pip-wheels:

    • Pip-wheel for Python 3.10 (in addition to Python 3.8) are now available for modular installation. This can be used to run CASA pip wheels in Google Colab. The all-inclusive monolithic CASA version runs on Python 3.8. (CASA 6.6.0)

    • Incompatibility issues with matplotlib for the Python 3.10 wheels in CASA 6.6.0 were resolved in CASA 6.6.3. (CASA 6.6.3)

  • Installation test script: a test script was added to the CASA packages for users to test their CASA installation. Test datasets will be downloaded on-the-fly. Users will need to pip install casatestutils prior to running the new tests if installing modular CASA. More information can be found on the CASA Docs Installation pages. (CASA 6.6.0)

Import/export and MS structure

  • multiple MSs input: clarifications have been added to the CASA logger on how the various CASA tasks handle the input of multiple MSs (concat, tclean, (t)sdimaging, sdintimaging). This is work in progress, and additional documentation will be provided in a next CASA release. (CASA 6.6.0)

Information

  • getantposalma: new task to query the ALMA antenna position web service and return a list of antennas with their ITRF positions. Warning: the web service itself has not yet been fully validated. (CASA 6.6.4)

  • Command-line exceptions: To allow for better testing and trapping of errors, CASA tasks now raise exceptions at the CASA command line instead of returning {{True}} on success and {{False}} on failure. (CASA 6.6.3)

  • Telemetry/crash reporter: the telemetry and crash reporter functionality was deprecated and removed from the code. (CASA 6.6.0)

Calibration

  • polfromgain: task polfromgain now permits specifying a minimum parallactic coverage threshold in the a new parameter: minpacov (default = 30 deg). This enables avoiding pathological cases of antennas with insufficient parallactic angle coverage which can yield spurious source polarization solutions or cause an exception to the thrown. (CASA 6.6.4)

  • getephemtable: a new task getephemtable was added to retrieve JPL-Horizons ephemeris data. (CASA 6.6.3)

  • getephemtable: the ‘posrefsys’ keyword of the output table was changed to ‘ICRS’, and support was added for source names containing non-alphanumeric characters. (CASA 6.6.4)

  • getcalmodvla: a new task getcalmodvla has been added to retrieve flux calibrator brightness distributions from a web service operated by the VLA, and create component lists which may then be used by tasks such as setjy to predict model visibilities. (CASA 6.6.3)

  • gencal: the parameter ant_pos_time_limit was introduced for gencal when used in the mode caltype=’antpos’. When specified (units are days), this parameter will limit the time following the observation for which antenna position corrections are included. This prevents antenna position corrections from being included that may have been determined many months to years after the observation was completed and do not reflect the actual antenna position at the time of observation. This can occur for antennas on certain pads that are not typically moved during configuration changes (generally pads E08, N08, and W08). If the parameter is not specified, the default behavior will include all position corrections that are in the database. (CASA 6.6.3)

Manipulation

  • setjy: the usescratch parameter now defaults to True, and usescratch=False is no longer allowed to be used with the Butler-JPL-Horizons standard. (CASA 6.6.4)

  • fixplanets: Functionality to attach JPL-Horizons ephemeris data in MIME format to an MS was removed from fixplanets as the underlying conversion function was no longer maintained. Task getephemtable can be used to query the JPL-Horizons web service and output the ephemeris table in CASA table format, which can be attached to an MS via fixplanets. (CASA 6.6.4)

  • defintent: a new task defintent was added to modify the scan intents of a measurement set. (CASA 6.6.0)

Imaging

  • tclean: a new parameter specmode=’mvc’ was added, which provides an alternative to specmode=’mfs’ when using the mtmfs deconvolver. This new mode combines cube major cycles with continuum minor cycles along with accurate wideband primary beam correction. It calculates the Taylor coefficient images from a coarse cube after doing a frequency-dependent primary beam correction. If using this new mode, one no longer needs to correct for the primary beam’s spectral index using the widebandpbcor task or the conjbeams parameter. This new mode is currently under active development with additional enhancements expected in a future release. (CASA 6.6.4)

tclean : new imaging mode (specmode=’mvc’) to combine cube major cycles with continuum minor cycles along with accurate wideband primary beam correction.

  • tclean: the return dictionary from tclean with niter=0 will no longer ignore \(<\)imagename\(>\).mask if it exists on disk.

  • tclean/sdintimaging: tasks sdimaging and tsdimaging were improved so that:

    • they internally sort input list of MSes in chronological order. Input MS lists are now sorted by time to provide improved consistency with the results from task_concat. CASA (6.6.3)

    • they check for mismatches in column states when given multiple input MSs, e.g. inconsistencies in optional columns such as WEIGHT_SPECTRUM. CASA (6.6.3)

    • a crash was fixed that could sometimes occur when given a list of measurement sets if there were inconsistencies in the data columns (e.g., WEIGHT_SPECTRUM). CASA (6.6.3)

  • tclean: algorithmic improvements were implemented to the ASP deconvolver when presented with a large spread of spatial scales. CASA (6.6.3)

  • deconvolve: enabled mtmfs as an algorithm option in the deconvolve task. (CASA 6.6.0)

  • sdintimaging: the default for the sub-parameter dishdia was previously 100.0 and it is now set to empty. The task sdintimaging will fail if dishdia is not set to different than None. (CASA 6.6.0)

  • tclean/deconvolve: return dictionaries were added for niter=0 calls, which contain information about peak residual (over the whole image) and total flux from the model image. Deconvolution masks are currently not made or used in the niter=0 call. (CASA 6.6.0)

  • image tool: a fitsheader member function was added to the image tool. This function returns the FITS header for the image represented as a Python dictionary. (CASA 6.6.0)

Visualization

  • plotms: correlation selection supports standard Stokes parameters and polarization quantities, which will be computed if they do not exist in the MeasurementSet. The selection must be combined with a visibility axis. (CASA 6.6.3)

  • plotms: the legend will identify the colorized values in the plot when coloraxis is set. (CASA 6.6.0)

  • plotms: a new boolean option colorizeoverlay was added to make the overlay a solid color (False) or colored according to the coloraxis (True). (CASA 6.6.0)

Single Dish

  • tsdimaging: a new parameter convertfirst allows improved performance by reducing the number of directions conversions. (CASA 6.6.4)

    • Backward compatibility note: tsdimaging parameters ordering has been modified. This may break existing scripts which call the task using positional arguments. (CASA 6.6.4)

  • tsdimaging: performance improvements

    • performance for ALMA Solar TP imaging was improved about 30%. (CASA 6.6.4)

    • overall performance was improved about 10% (level of improvement depends on data size). (CASA 6.6.0)

  • sdimaging: a new parameter convertfirst allows improved performance by reducing the number of directions conversions. (CASA 6.6.0)

Bug fixes

  • gaincal: fixed a segfault when running on an MS for which the model was saved as virtual (usescratch=False). CASA (6.6.4)

  • flagdata: a bug was fixed whereby wrong commands that try to flag calibration tables using the correlation parameter in manual mode would erroneously flag the table in erratic ways. CASA (6.6.4)

  • tsdimaging: a bug has been fixed where multiple input MSs are internally sorted in chronological order, and their corresponding data selection parameters are now correctly sorted accordingly. CASA (6.6.4)

  • plotms: a bug was fixed that could produce erroneous values when plotting weight and iterating by correlation. CASA (6.6.4)

  • tclean: a bug was fixed when the input ephemeris table’s name began with a known Measures ephemeris object. Additionally, the documentation improved and an error message was added for when the phasecenter parameter contained an improperly specified ephemeris table’s path. CASA (6.6.4)

  • imsmooth: an accounting error that caused a bug in which polarizations > 0 were not processed for multi-channel, multi-polarization images in ia.convolve2d() and imsmooth (for 2d gaussian convolution modes) was fixed. CASA (6.6.4)

  • plotbandpass: an exception that could sometimes be raised for ‘overlayColors’ was fixed. CASA (6.6.4)

  • plotbandpass: two items were fixed: 1) treating an air pressure value correctly for NRO data; 2) replaced the fixed geometric elevation value with calculated one using ANTENNA table. CASA (6.6.4)

  • tec_maps: the tec_maps.py helper script (for retrieval of tec information for ionospheric corrections) has been updated to be consistent with the new file-naming convention on the remote CDDIS server. CASA (6.6.3)

  • flagdata: a bug was fixed when using basecnt=True, whereby some log messages would mislabel scans as correlations and antennas as SPWs. (CASA 6.6.3)

  • tclean: If a user intentionally supplied a zero-filled mask to tclean, it would flip it to a one-filled mask and proceed with deconvolution. This has been changed to now detect a zero-filled mask and exit based on the zero mask stopping criterion. (CASA 6.6.3)

  • tsdimaging: description of type of suffixes of a parameter outfile was fixed (CASA 6.6.3)

  • plotbandpass: fixed a failure when the caltable contains a totally flagged spw on the final antenna. (CASA 6.6.3)

  • plotbandpass: a colorization issue using the same color for all timestamp was fixed (CASA 6.,6.1, 6.6.3)

  • plotms: interactive flagging in fringefit solution tables was fixed. (CASA 6.6.3)

  • gencal: a bug was fixed where if jyperk caltype raised exception, it did not forward the message describing the problem. (CASA 6.6.0)

  • tclean: a bug was fixed where the mtmfs deconvolver incorrectly reported the peak residual value at the end of the minor cycle of tclean. (CASA 6.6.0)

  • tclean: a bug was fixed with mtmfs deconvolver in tclean, where imaging with multiple Stokes planes would not correctly write the restoring beam information into the image header. (CASA 6.6.0)

  • tclean: an edge case was fixed where tclean would crash when attempting to make a cube when provided multiple MSs with different SPW configurations (number, channelization). This was only triggered by very specific configurations of input data. (CASA 6.6.0)

  • plotms: Fixed a bug in plotms, where antenna selection with iteration did not show all the selected baselines. (CASA 6.6.0)

  • plotms: a bug was fixed where the point size was ignored when using a coloraxis. (CASA 6.6.0)

  • plotbandpass: a bug was fixed in a logic to group data on the time axis. (CASA 6.6.0)

  • sdimaging: eliminated false warning message from Measures module. (CASA 6.6.0)

Documentation

  • CASA Docs: added a Frequently Asked Questions (FAQ) section with user questions and answers. (CASA 6.6.4)

  • Archival documentation: old versions of CASA Docs were removed to optimize Google searches (critical information remains available on the current CASA Docs for v.4.7+)

Known Issues

Summary Most Important Issues

  • The CASA Viewer no longer launches on Mac OS 14, and is not included in the ARM builds for Mac OS 13 and OS 14.

  • Task wvrgcal is not included in the Python 3.10 versions for both Linux and Mac OS.

  • Addition of a new casaconfig package in 6.6.4 triggered the following Known Issue:

    • gencal with caltype=’gc’ and ‘gceff’ cannot find the /data/nrao/VLA/GainCurves table

  • Task simanalyze with two or more input MSs in vis may not work.

  • In tclean, major cycles can be trigger too early due to psfsidelobe.

  • For VLA data, importasdm with polyephem_tabtimestep <= 0 does not disable tabulation, but sets intervals to 0.001.

  • In tclean, pbmask uses the wrong default of 0.2 for usemask=’pb’ and ‘auto-multithresh’.

  • The modular version of importfits may fail with CFITSIO error if NASA’s HEASoft is installed.

  • Tasks mstransform and split switch the circular (linear) polarization products when input is given as correlation=’ll,rr’ (‘yy,xx’).

  • In fringefit, parameters corrcomb=’all’ and corrdepflags=True are currently not compatible and can yield excessive flagging.

  • The Adaptive Scale Pixel (asp) deconvolution algorithm in tclean is experimental, and we welcome user feedback.

  • CASA 6 startup may fail on some Mac OS where users have set up a file system that is case-sensitive.

  • Wideband and widefield imaging in tclean are only partially validated - please use at own risk and read wideband and widefield documentation.

  • For VLA antenna position corrections in gencal, lines in the position-corrections file are ignored if X (Bx) and Y(By) corrections are both ‘0’, but Z (Bz) is not ‘0’.

  • When imaging large mosaics with mosweight in tclean, an error “too many open files” may occur that may require to increase the limit for open files.

  • stawt may fail when the correlator integration time changes within an MS and statwt is run with timebin set to an integer value.

  • CASA is not using LD_LIBRARY_PATH anymore but CASALD_LIBRARY_PATH to avoid confusion.

  • cvel is calculating the velocity incorrectly for ephemeris objects. We recommend to use mstransform or its offspring cvel2, although the latter should be used with care as it is not fully commissioned yet.

  • fixvis uses the small angle approximation and may be incorrect for large phase shifts. Use the new task phaseshift instead, or use tclean for phase center shifts during imaging when applicable.

  • With parallel calibration on MMS files, fixvis does not write out the the new MMS specified in outputvis correctly, hence fixvis solutions are not applied when writing to a new MMS.

  • In tclean, using the mosaic gridder with the default nchan=-1 is in some cases known to produce errors.

  • Ionospheric TEC corrections are currently validated in CASA only for VLA data.

  • ephemeris objects are not correctly supported by virtual model columns.

  • In tclean, the combination of specmode=’cube’ and gridder=”awproject” has not been commissioned for use and may result in errors.

General

Several issues have been encountered for CASA 6:

  • inp/go syntax does not reset hidden parameters to default between consecutive calls. The most notable issue occurs with the selectdata parameters; once set at selectdata=True, any associated subparameters that are changed from default (e.g., spw, or field) will remain even after re-setting to selectdata=False. Generally this should not matter as hidden parameters are not used. However, known exceptions exist in tclean, sdintimaging, apparentsens, setjy, listvis, sdcal, and sdfit where the value of hidden selection parameters does in fact matter. We are currently investigating the extent of this problem. As a workaround, users can call default to manually reset all their parameters.

  • inp/go does not work for the following tasks: msuvbin, browsetable, imview, msview, deconvolve, testconcat. Please invoke the arguments directly when running these tasks in CASA 6.

Installation

  • The CASA Viewer (tasks imview, msview) no longer launches on Mac OS 14, instead returning the error: Library not loaded: /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Print.framework/Versions/A/Print. The CASA Viewer is no longer included on ARM builds for OS 13 and 14. Instead, please use the CARTA visualization software: https://cartavis.org/. Due to this bug, tclean will not work in interactive mode on Mac OS 14 until a standalone widget for interactive tclean (currently under development) is released. The Mac OS 12 Intel version is known to work on OS 13 (but not 14) to provide this capability.

  • Task wvrgcal is not included in the Python 3.10 versions for both Linux and Mac OS. Please use the Python 3.8 versions instead.

  • Running importfits in modular CASA may fail with a CFITSIO error if also the NASA HEASoft software is installed, because of a conflict in CFITSIO setting between CASA and heasoft. As a workaround, comment out all parts of heasoft in your environment to made importfits work in the modular environment.

  • CASA 6 startup may fail on some Mac OS where users have set up a file system that is case-sensitive (as shown here). As a temporary work-around, please manually update the casapy script in /Applications/CASA.app/Contents/MacOS/casapy, by replacing the string “Macos” with “MacOS”, which occurs in lines 36 and 39 of the casaspy script.

  • For Mac OS, the default behavior when downloading multiple versions of CASA is to call it “CASA X.app” (i.e., including a space). However, CASA is unable to find the viewer when a space exists in the application name. The workaround is to rename the application excluding the space.

  • If you use a version of RHEL6 with a kernel version that is older than 2.6 you may encounter an error like:

E0324 17:24:18.576966686   27444 tcp_server_posix.cc:65]     check for SO_REUSEPORT:
{"created":"@1585038258.576951288","description":"OS Error","errno":92,"file":
"src/core/lib/iomg/socket_utils_common_posix.cc","file_line":168,"os_error":"Protocol
not available","syscall":"setsockopt(SO_REUSEPORT)"}
  • NFS mounted disks

    • It is not recommended that you run CASA (e.g. have your data) on disks that are NFS mounted. It can be done, but in some cases the files will be NFS locked and this can crash CASA or its tasks. In this case, you have to restart CASA.

    • If you receive messages like xvfb timeout you may try to clean out your /tmp folder, then restart CASA.

  • Python:

    • Environment variables set for personal use may be incompatible with CASA 6, given that the CASA comes with a Python version that may be different from the one installed for regular use. It is still unclear which specific errors can occur, but one workaround solution for these types of errors is to unset PYTHONSTARTUP before starting casa. We are looking into possible solutions.

    • Files in the current directory with the same name as ipython files will cause errors like this error that occurs when a new.py file exists in the current directory: ```python

AttributeError                            Traceback (most recent call last)
/lib/python2.7/site-packages/IPython/core/interactiveshell.pyc in enable_matplotlib(self, gui)
   2945                 gui, backend = pt.find_gui_and_backend(self.pylab_gui_select)
   2946
-> 2947         pt.activate_matplotlib(backend)
   2948         pt.configure_inline_support(self, backend)
   2949

/lib/python2.7/site-packages/IPython/core/pylabtools.pyc in activate_matplotlib(backend)
    292     matplotlib.rcParams['backend'] = backend
    293
--> 294     import matplotlib.pyplot
    295     matplotlib.pyplot.switch_backend(backend)
    296

/lib/python2.7/site-packages/matplotlib/pyplot.py in <module>()
     21 from matplotlib.cbook import dedent, silent_list, is_string_like, is_numlike
     22 from matplotlib import docstring
---> 23 from matplotlib.figure import Figure, figaspect
     24 from matplotlib.backend_bases import FigureCanvasBase
     25 from matplotlib.image import imread as _imread

/lib/python2.7/site-packages/matplotlib/figure.py in <module>()
     16 import artist
     17 from artist import Artist, allow_rasterization
---> 18 from axes import Axes, SubplotBase, subplot_class_factory
     19 from cbook import flatten, allequal, Stack, iterable, is_string_like
     20 import _image

/lib/python2.7/site-packages/matplotlib/axes.py in <module>()
   8452
   8453 #This is provided for backward compatibility
-> 8454 Subplot = subplot_class_factory()
   8455
   8456 docstring.interpd.update(Axes=martist.kwdoc(Axes))

Scripting

  • Starting CASA 6: For “execfile” calls within a script which itself is run via “execfile”, it is necessary to add globals() as the second argument to those “execfile” calls in order for the nested script to know about the global variables of the calling script. For example, within a script ‘mainscript.py’, calls to another script ‘myscript.py’ should be written as follows: execfile(‘myscript.py’, globals()).

  • There are cases where two scripts call on each other (i.e., where script “a” uses script “b” and vice versa). In casa 6, the only way to execute these scripts is by running the first script twice:

execfile("a.py",globals())
execfile("b.py",globals())
execfile("a.py",globals())

Import/export

  • When importing VLA data (with polynomial ephemerides) using importasdm, setting the parameter polyephem_tabtimestep to <= 0 (with 0.0 being the documented default), the tabulation is not disabled (as documented), but reverts to a default value of 0.001s. This issues does not affect ALMA data, because ephemeris data are stored in tabulated format in the ASDM. This issue will be fixed in a next CASA release.

  • Import/export of MSs with Nant>255 via UVFITS is implemented according to AIPS Memo 117, but should be considered experimental and datasets transported this way may not behave as expected in other packages (e.g., AIPS).

statwt

  • In some circumstances when an MS data selection is specified, chanbin is not equal to the default value of spw, and the WEIGHT_SPECTRUM or SIGMA_SPECTRUM columns don’t exist, the statwt task may need to be run twice in order to complete successfully due to a known issue with initializing the WEIGHT_SPECTRUM and/or SIGMA_SPECTRUM columns in the code. In these circumstances, an exception will be raised with instructions to restart the task. If you are using the tool method, first close the ms tool, then reopen it using the same data set, apply the same selection, and then run ms.statwt().

mstransform/split

  • Tasks mstransform and split switch the circular or linear polarization products when input is given as correlation=‘ll,rr’ or correlation=‘yy,xx’. In those cases, the original rr (xx) correlation turns into ll (yy) in the output MS, and ll (yy) turns into rr (xx). This is opposite from the correct behavior when correlation=‘rr,ll’ or correlation=‘xx,yy’, in which case the polarization products remain unchanged in the output MS. Other parameters do not show this behavior. As a workaround, specify the correlation products in the order that they appear in the input MS, i.e., correlation=‘rr,ll’ for VLA and correlation=‘xx,yy’ for ALMA data.

  • SPW combination (combinespws=True) requires that all the SPWs selected have the same number of channels.

  • Some inconsistencies are present in CASA in the SIGMA/WEIGHT columns (and their _SPECTRUM variants) when splitting on datacolumn=’data’, such as: - For an MS with WEIGHT_SPECTRUM but no SIGMA_SPECTRUM (as obtained from initweights), SIGMA_SPECTRUM is created and initialized to SIGMA. While split/mstransform correctly initializes the output WEIGHT to 1/SIGMA^2, it does not initialize the output WEIGHT_SPECTRUM to 1/SIGMA_SPECTRUM^2 (instead it copies the original WEIGHT_SPECTRUM). - For an MS with both WEIGHT_SPECTRUM and SIGMA_SPECTRUM, the output WEIGHT_SPECTRUM is again a copy of the input instead of being initialized to 1/SIGMA_SPECTRUM^2.

Future work in CASA is planned to address such inconsistencies.

cvel

  • cvel is calculating the velocity incorrectly for ephemeris objects. We recommend to use mstransform or its offspring cvel2, although the latter should be used with care as it is not fully commissioned yet.

  • cvel fails on MMS files used for parallel processing. We recommend to use mstransform or its offspring cvel2, although the latter should be used with care as it is not fully commissioned yet.

gencal

  • gencal with parameters caltype=’gc’ and ‘gceff’ results in an error that the /data/nrao/VLA/GainCurves table cannot be found. As a workaround, we recommend using the infile parameter: infile=ctsys.measurespath()+'/nrao/VLA/GainCurves' This error appears to be due to a broken linkage to the data repository related to the new casaconfig package, and therefore only affects CASA 6.6.4 and up. No other such examples were found in the code.

  • For correcting VLA antenna positions in gencal, there is a bug that entry-lines in the position-corrections file are ignored if X (Bx) and Y(By) corrections are both ‘0’, but Z (Bz) is not ‘0’. In other words, lines for which (Bx = 0, By = 0, Bz != 0) are not included in the (cummulative) correction factor.

bandpass

  • Currently, bandpass will not find good solutions if any correlation (including cross-correlation) in the data is completely flagged. As an interim solution one may split the unflagged data in a separate file and then perform bandpass

polcal

  • Polarization position angle calibration poltype=’X’ or ‘Xf’ will be sensitive to any unmodelled position shift in the specified calibrator linear polarization model relative to the centroid location of total intensity (typically the phase center). Excess phase due to the position shift will introduce a bias in the cross-hand phase calibration (which is the same as position angle calibration in the circular feed basis). For this reason, it is best to use truly point-like (in all polarizations) calibrators, if possible, or accurate resolved models.

setjy

  • For setjy, setting a virtual model with usescratch=False (which is the default) can result in a segfault when subsequently running task gaincal. To avoid this, please change to usescratch=True.

  • Sometimes setjy does not properly overwrite a current model in the header of the ms (virtual scratch column). It is recommended to use delmod if a model exists and shall be overwritten.

-    *virtual model columns* in the MS do not correctly support *ephemeris* objects, although they will run without generating errors or warnings. If any of your calibrators exhibit significant celestial motion on the timescale of your observation (e.g. , any solar system object), you must set *'usescratch=True'* in calls to **setjy()**.

uvcontsub

  • fitorder should be kept low (<= 1) unless the line band is relatively narrow compared to the fit bands. If the image rms markedly rises in the middle line channels after uvcontsub, fitorder should probably be lowered.

  • fitorder > 0 does not work with solint > ‘int’

cal library

  • The CASA cal library (docallib=True in applycal, gaincal, bandpass, etc.) may exhibit problems when calibration is unavailable for a subset of MS spectral windows. Use of spwmap to (transparently, harmless) supply nominal calibration for these spectral windows may help avoid this problem. For antenna position corrections, try spwmap=[0] to relieve a variety of this problem.

VLA Switched Power

  • In CASA v4.2.2 and higher, the weight calibration for EVLA switched power/Tsys corrections is still being investigated. Visibility corrections are ok. Since switched power calibration is not used by the EVLA pipeline (except for requantizer gain corrections, for which this problem is irrelevant), and since calwt=F remains the general recommendation, users should rely on statwt to generate appropriate data weights.

fringefit

  • In task fringefit, use of corrcomb=’all’ (to combine correlations for a single solution) with corrdepflags=True (to respect correlation-dependent flags) are currently not compatible and can yield excessive flagging in the resulting solutions.

  • In fringefit, corrcomb=’all’ will flag all solutions for antennas with only one polarization.

  • For task fringefit, calibration tables created with CASA 5.5 and before cannot be applied with CASA 5.6 and later. Attempting to do so will fail with an error about non-confirming array sizes.

fixvis

  • **fixvis** uses the small angle approximation and may be incorrect for large phase shifts. This may result in sources shifting position if large phase shifts are being applied (shifts up to a few beam sizes have been reported). Please use the new task **phaseshift** instead, or use **tclean** for phase center shifts during imaging when applicable.
    
  • With parallel calibration on multi-MS (MMS) files, fixvis does not write out the outputvis correctly, hence fixvis solutions are not applied when writing to a new MMS. The recommended work-around solution is to over-write the input MMS by leaving the outputvis parameter empty. This will change the input MMS, so if you are concerned about that, we recommend to make a copy before running fixvis in parallel mode. Writing output MS files in serial mode is not affected by this bug.

tec_map

  • Ionospheric TEC corrections in CASA are currently validated only for the VLA. TEC corrections for other observatories are experimental and should be done at your own discretion.
    
  • Do not use CASA 6.1.0 for tec_map corrections.
    

tclean

  • interactive tclean is not possible on Mac OS 14 due to a bug in the CASA Viewer not launching on OS 14. While CARTA (https://cartavis.org/) can be used as an alternative for the Viewer, it does not support interactive tclean. A stand-alone widget is currently under development by the CASA team, and will be available in the near future.

  • The calculation of psfsidelobe, used to determine cyclethreshold, can often pick a value higher than the first sidelobe level, causing major cycles to be triggered too early. Please use cyclefactor<1.0 to compensate in well-constrained imaging cases where deeper minor cycles are possible.

  • The parameter pbmask has a default value of 0.0 for usermask=’user’, but 0.2 for usemask=’pb’ and ‘auto-multithresh’, even though the documented value is 0.0 for all options. This bug will be fixed in a future release. As a workaround, please set the value manually.

  • For the experimental ‘Adaptive Scale Pixel (asp)’ deconvolution algorithm in tclean:

    • This algorithm implementation is experimental and has had limited testing. We are currently investigating some intermittent failures on some flavors of Mac OSX. We have follow-up development and test efforts, and encourage users to provide feedback on what they find.

    • 3rd party code used for the core optimization (lbfgs) is known to produce different numerical results depending on the compiler/build options. We have tested this on all CASA’s supported platforms for the use cases included in our characterization demo and for these tests the results are scientifically equivalent.

  • The gridder=’awproject’ has not been fully commisisoned for use with specmode=’cube’ in tclean. The following message appears: The gridder=’awproject’ has not been fully tested for ‘cube’ imaging (parallel=True or False). Formal commissioning of this mode is expected in a subsequent release, where ‘awproject’ will be aligned with recent framework changes. Until then, please report errors/crashes if seen.

  • In tclean, if gridder=’awproject’ is run with psterm=True, the output Primary Beam currently still includes the Prolate Spheroidal function. In order to do a primary beam correction, a separate PB needs to be made with psterm=False. See the CASA pages on AWproject for more information.

  • For widefield imaging in tclean, the following features still need to implemented and commissioned (for usepointing=True, with full heterogenous pointing support): - gridder=’mosaic’ : Enable accurate pointing corrections for baselines with antennas pointing in different directions

  • In tclean, the gridders ‘mosaic’ and ‘awproject’ include aperture illumination functions in the gridding convolution functions used for the PSF generation. Although this strictly follows the math, it has several undesirable features especially in the situation where data are not uniform across all axes across which they are being combined (i.e. if the mosaic pattern is not relatively flat, if the center of the image has no mosaic pointing, if different pointings have drastically different uv-coverages or frequency coverages). All such variations cause the PSFs to be position-dependent and could relate to potential instabilities during deconvolution, either requiring many major cycles to converge or diverging. For spectral-cube imaging, the effects are lower because PSFs are normalized to peak 1 no matter what their raw peak values are. For multi-term imaging, the ratios between the spectral PSF central values matter and the effect/error is enhanved. When all these uv-coverage variations are avoided (in careful simulations), both algorithms perform as expected for joint wideband mosaics (both with conjbeams=True or False). For CASA 6.3, the guidelines are:
    - For the standard gridder, full-field, single pointing imaging (spectral cube as well as multi-term) will be accurate as long as the image phase center matches the PB pointing center.
    - For multi-term wideband joint mosaics, we recommend the use of gridder=’awproject’ with conjbeams=True as that is the only combination that has demonstrated accurate wideband pb-correction (at niter=0) especially in the presence of position-dependent uv-coverage. All other options will need monitoring and several major cycles to ensure convergence. The image should ideally be centered on a PB center.
  • In tclean, the mosweight parameter for multi-field imaging has a new default value of mosweight=True as of CASA 5.4. The new default setting of mosweight=True in tclean optimizes noise characteristics for Briggs/uniform weighting, but one should be aware that it has the following disadvantages: - it may potentially cause memory issues for large VLA mosaics - the major and minor axis of the synthesized beam may be up to ~10% larger than with mosweight=False - Please change to mosweight=False to get around these issues.

  • When imaging mosaics with a large number of fields and many MSs in tclean, an error can occur that specifies too many open files. This can happen for both manual and pipeline imaging when using the mosweight=True parameter. The reason is that in CASA 5.5, a trade-off was made to reduce memory demands in tclean when using mosweight, by placing the weights on disk using multiple files. Unfortunately, this memory fix may cause open file problems for data sets consisting of many MSs and fields. The problem has been characterized based on the number of MSs and fields: with respect to earlier CASA releases, the imager code now uses #MSs x #fields x 2 additional files. In CASA 6.2 and 6.3, the number of open files required for the default perchanweightdensity=True case has been dramatically reduced, though perchanweightdensity=False imaging runs are more limited. While the CASA team is working on a permanent solution for future CASA versions, the recommended work-around solution is to manually increase the limit for the number of open files, e.g.: ulimit -Sn 8000 or ulimit -Sn 16000. In some cases, increasing the hard-limit on number of open files may be necessary, which requires admin/root permissions. As a rule of thumb, each MS requires ~54 simultaneously open files. With a 16k limit and a maximum of 150 fields per MS, for a use case with perchanweightdensity=False, mosweight=True tclean will encounter too many open files with ~46 MSs or more, while with perchanweightdensity=True, mosweight=True tclean will encounter too many open files with ~300 MSs or more.

  • There are small, systematic offsets known to occur when using tclean. Our initial tests show that the offset in dec is of the order ~50 milli-arcsec, while the offset in RA is a function of declination, but also amounting to ~50mas. This issue is currectly being investigated.

  • Currently the parameter type of niter is defined as an integer, therefore the integer value larger than 2147483647 will not be set properly as it causes an overflow.

  • Using deconvolver=’mtmfs’, nterms=1 and specmode=cube does not yet work in parallel imaging mode. Use specmode=’mfs’ instead.

  • The awproject gridder in tclean does not support the virtual model scheme.

  • Interactive tclean only works when a region or mask is selected in the CASA Viewer. There is a known bug that when a region is first selected, and then de-selected to produce an empty mask (filled with zeros), the CASA Viewer that runs interactive tclean will still allow you to proceed, and tclean will detect an empty mask and stop. Please always mark a region/mask to continue interactive tclean (if the entire image should be cleaned, draw a box around the entire image), and do not forget to double-click inside the green contours to select the region.

  • When using interactive tclean, hand-edited cyclethresholds do not change back to the auto-calculated values in the GUI until two major cycles later. However, the logger contains the most accurate information about what was used, and the expected behaviour (of hand-edited cyclethresholds applying to only the current minor cycles) is seen and has been tested. Therefore, iteration control and imaging will proceed as expected. This known issue affects CASA versions 5.6 and 5.7/6.1

  • In the makemask task, region files using the minus sign ( - ) to create cutouts are known not to work.

  • The combined imaging of different large MSs where differences in the topo-centric frequencies are large compared to the channel width can fail in tclean as a result of memory issues, in particular when imaging in parallel mode. A potential workaround solution is to use the task concat to first combined the MSs before running tclean, although further testing is needed to ensure that this solution is valid for all cases. This issue will be fixed in a next CASA release.

imregrid

  • Position-velocity (PV) images are not supported by imregrid, because their coordinate systems are nonstandard, lacking a direction coordinate and having a linear coordinate.

  • When converting from between coordinate system that require rotation (e.g., from celestial to galactic coordinates), CASA is known to introduce deviations in position from other software packages that can be several tenths of an arcsec. This could be because the rotation of the rectangular grid in a non-cartesian coordinate system is imperfect, possibly due to internal inconsistencies in the conversion matrices. The conversion between one frame and another in general becomes less accurate as distance from the output image’s reference pixel increases. The imregid task and Measures tool suffer from this Known Issue (see imregrid task page).

viewer

  • The CASA viewer does not yet support the entire region shapes and parameters at this stage.

  • For equatorial cubes, i.e. data cubes that include dec=0 (exact), the viewer only gives spectra for sources at dec > 0. No spectra are produced for any points with dec <0.

  • Viewer may not properly open saved region files.

  • With the new region panel being used now, It may be advisable to rename the $HOME/.casa/viewer/rc file that stores previous configurations of the viewer.

  • Viewer - labels are not shown - this can be caused by a conflict between an installed version of PGPLOT and the version of PGPLOT that comes with the non-root version of CASA. If you do have PGPLOT installed in a standard location (e.g. /usr/lib), you may try moving it aside and see if it resolves the problems. If you do encounter this problem, please report it to the CASA team.

  • Some X11 settings can make the viewer unstable. We identified that the line Load “glx” in /etc/X11/xorg.conf is such a setting. If you don’t need this line for aother applications, it would be better to have it removed.

  • The viewer can only load MeasurementSets (MS) for which all spectral windows have the same channel width. If this is not the case, an ArrayColumn error will appear. To get around this, use SPLIT`` to place the spectral windows of interest in a separate MS, or try the table browser tool.

  • When exiting CASA after using the viewer, a message similar to the following may appear: proc vtool_1EziEss1P2tH0PxJbGHzzQ is being killed. This is a cosmetic issue and can be ignored.

  • For some OSs and window managers, parts of the display may be eclipsing interactive elements. We recommend to change the window manager styles for these cases.

  • When multiple animators are open, it can happen that it is not possible to make them active, when the ‘Images’ animator is inactive. Active the ‘Images’ animator first to enable the other animators.

  • MeasurementSet with sizes of tens of Gb may not visualize the full data set properly on all machines, which can give the appearance that part of the data is flagged.

  • The line tool in the MAC viewer plots unreadable hex numbers.

plotms

  • In plotms, PDF and PS exports have been reported not to work with some older sub-versions of RH7 (e.g., RH 7.6). While the problem has not been completely characterized, upgrading to a newer RH version (e.g., RH 7.9) has shown to solve this issue.

  • In RedHat 7 we found that in some circumstances the vertical tab of the viewer appears on the right hand side instead of the left hand side. This eclipses the scrollbar and makes it difficult to use. To fix, add the following to the top of ~/.config/Trolltech.conf

```
[[Qt]]{.error}

style=GTK+
```
  • When plotting pointing axes in plotms on RHEL6, the tick-values of minutes and seconds on the axes are not multiples of 5

  • For concatenated data sets, plotms can create an output error if certain data columns were present in some of the concat input MSs, but missing in others (making concat inset zero values). A practical workaround is to either handle the MSs separately, or delete those columns using the tb.removecols tool (but in case of the latter one has to take care that the columns are not crucial).

uvmodelfit

  • When running uvmodelfit, the output componentlist does not contain the uncertainty in flux that the task calculates (and displays at the end of the fitting process).

imstat

  • The use of the “centerbox” parameter when specifying a region in imstat has a known issue that under very specific circumstances, less pixels are taken into account for the statistics than what is expected. This only occurs when all of the following are true: (1) values are specified in pixels; (2) the width of the box is an even number of pixels (e.g, 4pix, 16pix, or 100pix); and (3) the box is located away from the image center in Right Ascension (progressively more pixels are dropped when moving away from the image center, but only in RA). The issue is a combination of machine rounding errors (when the boundary of the centerbox is exactly at the center of a pixel), and the fact that centerbox has to converts pixel coordinates to sky coordinates to allow all possible combinations of regions. Note that the “box” parameter is not affected by this, because it can be more strict in only using flat pixel coordinates. As a simple work-around solution, we recommend to always give the width of the centerbox in “odd” number of pixels. Please note that because centerbox places the center of a box in the middle of a pixel and CASA only includes full pixels, the width of a centerbox always has an odd number of pixels anyway. For example, centerbox=[[1000pix,4000pix],[4pix,4pix]] for an 8000x8000 pixel image should give npts=25, but due to the above issue will result in npts <25. Instead, centerbox=[[1000pix,4000pix],[5pix,5pix]] will always give npts=25.

tb.statistics

  • The table tool’s statistics function tb.statistics currently ignores the useflags parameter, so statistics are calculated for all values in the specified column, and flagged values cannot be avoided.

simobserve / simanalyze

  • For simanalyze, when added two or more input MSs in the vis parameter (when combining an INT+SD or INT+INT data), tools may not be appropriately initialized or accessed in CASA 6. As a workaround, use tclean or sdintimaging for combining the simulated output MSs from simobserve.

  • When using simobserve to simulate a spectral cube, using the inwidth parameter with units of velocity (e.g., kms/s) is known to produce wrong results. Use inwidth with frequency units instead (e.g., inwidth=‘1MHz’).

  • CASA simulations do not yet fully support all spectral types of components (i.e., ability to include spectral lines or spectral indices)

  • When cleaning with a simulated MS, it should be considered best practice to declare the phasecenter parameter using the ‘J2000 xx:xx:xx.xxx +xxx.xx.xx.xxx’ notation to account for possible rounding errors that can create an offset in the image.

  • corruption of simulated MS by an atmospheric phase screen is only available from the toolkit. simobserve and sm: Under some circumstances, running sm.setnoise and sm.corrupt, or simobserve with thermal noise, twice using the same project name, the noise can be applied a second time, doubling the noise level. Be sure to use different project names for creating different simulations with noise. See casaguides.nrao.edu for the latest simulation information

single dish

  • Difficulty in allocating memory to import/processing of Band 9 (fast-mapped, double-circle) data. Use high-performance machines as workaround.

  • Please avoid using spectral window and channel selection by frequency range. It may occasionally fail. So far, this has only been reported on Mac OS but it may happen on Linux, too.

sdimaging

  • sdimaging task may fail when more than several MSes are chosen as inputs (infiles) to create single output image. It is because the file descriptor opened by the task exceeds the limit defined by OSes. You can relax the limit of the number of open file descriptors by the command, e.g., ulimit -n 4096 . Note the typical number of file descriptors opened by the task is 35/MS.

sdintimaging

  • For task sdintimaging, gridder=’awproject’ is not yet available. It will be enabled in a subsequent release.

Compatibility

The CASA software is available for mutiple LINUX and Mac computer operating systems, as well as multiple versions of Python. The compatibility matrix below shows the different Operating Systems and Python versions on which current and future CASA versions are expected to work, and for which the CASA team accepts bug reports.

However, note that CASA is only validated against the operational configuration of NRAO instruments.

Further differences exist between the monolithic CASA distribution (which includes all packages and a relocatable copy of Python) and modular CASA (in which the user supplies their own Python environment).

Refer to the following matrix for current and future planned compatibility.

Full Monolithic Distribution

Python 2.7

Python 3.6

Python 3.7

Python 3.8

Python 3.10

RHEL 6

<=6.3

6.2

6.2

RHEL 7

>=6.0, <6.5.6

>=6.2,<6.5.6

>=6.2

RHEL 8

>=6.0

>=6.4,<6.5.6

>=6.4

>=6.6.4**

Ubuntu 18.04

>=6.0, <6.5.6

>=6.2,<6.5.6

>=6.2

Ubuntu 20.04

>=6.0, <6.5.6

>=6.2,<6.5.6

Ubuntu 22.04

>=6.6.4

Mac OS 10.14

>=6.1, <6.2

<=6.3

Mac OS 10.15

>=6.1, <6.5.2

>=6.3, <6.5.2

Mac OS 11 x86

>=6.3, <6.5.6

>=6.3, <6.5.6

Mac OS 12+ x86

>=6.4

Mac OS 12 ARM

(>=6.4)*

Mac OS 13 ARM

(>=6.4)*

>=6.6.4**

Mac OS 14 ARM

>=6.6.4**

Note

*Use packages built for Mac OS 12 on x86 systems and run on ARM via Rosetta.

**Python 3.10 packages do not include task wvrgcal. The Mac OS ARM builds do not include the CASA Viewer (task imview, msview).

For plotms to work on Mac OS 12 and 13, XQuartz needs to be installed.

Modular CASA

Python 2.7

Python 3.6

Python 3.7

Python 3.8

Python 3.10

RHEL 6

<=6.3

6.2

6.2

RHEL 7

>=6.0, <6.5.6

>=6.2,<6.5.6

>=6.2

>=6.6

RHEL 8

>=6.0

>=6.4,<6.5.6

>=6.4

>=6.6

Ubuntu 18.04

>=6.0, <6.5.6

>=6.2,<6.5.6

>=6.2

>=6.6

Ubuntu 20.04

>=6.0, <6.5.6

>=6.2,<6.5.6

>=6.6

Ubuntu 22.04

>=6.6.4

Mac OS 10.14

>=6.1, <6.2

<=6.3

Mac OS 10.15

>=6.1, <6.5.2

>=6.3, <6.5.2

Mac OS 11 x86

>=6.3, <6.5.6

>=6.3, <6.5.6

Mac OS 12 ARM*

>=6.4

>=6.6

Mac OS 13 ARM*

>=6.5.5

>=6.6

Mac OS 14 ARM*

>=6.6.4

WARNING: The 6.2.1 module of casatools is not available for Python 3.7.

Notes

*Packages are built for macOS 12 on x86 systems and should run on ARM via Rosetta.

Older versions of CASA may not be compatible with the latest Operating Systems (for example, an appropriate usage mode on RedHat8 for CASA versions older than 6.3 has not yet been defined/tested). A listing of previous CASA versions and their supported OSs can be found on the CASA website.

The AppImage software is used to package the GUIs that are part of CASA. Users need to have the FUSE software installed, so these applications and be mounted and CASA can be run in its entirety.

casaplotms became available for all Linux/Python 3.x combinations beginning in 6.1

casaviewer became initially available in 6.2 and fully supported in 6.3

As of 6.5.6 there are El7 and El8 versions of the Linux tarball and casatools wheels.

Automated testing

Automated tests, used for verification during the development cycle and for new release versions, are run on a number of platforms. These include automated tests for CASA tasks, tools, and auxillary repos (e.g., Viewer, PlotMS, almatasks), as well as stakeholder tests, regression tests, and mpi tests. Entries marked with a “T” in the following table indicate versions of these automated tests in CASA 6.6:

OS

casatasks

casatools

casashell

aux repos

stakeholders

regressions

mpi

RHEL 8 + Py 3.8

T

T

T

T

T

T

T

RHEL 7 + Py 3.8

T

T

T

T

Ubuntu + Py 3.8

T

T

T

Mac OS 12 M1 + Py 3.8

T

T

N/A

N/A

Mac OS 12 + Py 3.8

T

T

N/A

N/A

Mac OS 13 + Py 3.8

T

T

T

N/A

N/A

RHEL 8 + Py 3.10

T

T

RHEL 7 + Py 3.10

T

T

Mac OS 12 M1 + Py 3.10

T

N/A

N/A

Mac OS 12 + Py 3.10

T

T

N/A

N/A

Automated tests, used for verification during the development cycle and for new release versions, are run on a number of platforms. These include automated tests for CASA tasks, tools, and auxillary repos (e.g., Viewer, PlotMS, almatasks), as well as stakeholder tests, regression tests, and mpi tests. Entries marked with a “T” in the following table indicate versions of these automated tests in CASA 6.5:

*Note: mpicasa, which is required for both mpi and stakeholder tests, is not supported for macOS.

Installation

A full installation of CASA including custom python environment is available as a Linux (.tar) or Mac (.dmg) file from our Downloads page (http://casa.nrao.edu/casa_obtaining.shtml)

The CASA 6.x series is also available as modular packages, giving users the flexibility to build CASA tools and tasks in their own Python environment. This includes the casatools, casatasks, and casampi modules, allowing for core data processing capabilities in parallel.

Prerequisite OS Libraries

CASA requires certain libraries be installed in the users operating system. Some may already be present by default. In case they are not, the following list should be checked before using CASA or if errors are encountered at runtime. Commands and package names are for Red Hat Linux, but equivalents can be found for other Linux distributions.

A system administrator may be required to install OS libraries. For example, for RHEL8 the following OS libraries should be installed:

  • $: sudo yum install ImageMagick*

  • $: sudo yum install xorg-x11-server-Xvfb

  • $: sudo yum install compat-libgfortran-48

  • $: sudo yum install libnsl

  • $: sudo yum install libcanberra-gtk2

ImageMagick can be obtained from EPEL 8: https://dl.fedoraproject.org/pub/epel/8/Everything/x86_64/Packages/i/. To add Epel via subscription manager (from RHEL docs):

  • $: subscription-manager repos --enable codeready-builder-for-rhel-8-$(arch)-rpms

  • $: dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

For modular CASA, one must supply their own Python environment. There are many, including ipython and Jupyter, here is a basic example:

  • $: sudo yum install python36-devel or python38-devel

When using the casampi package from modular CASA, additional MPI libraries are needed:

  • $: sudo yum install openmpi-devel

  • $: sudo yum install mpich-devel

  • User installs mpi4py with:

-    ```$: env MPICC=/usr/lib64/openmpi/bin/mpicc python -m pip install mpi4py --no-cache-dir```
-    Ensure mpirun is found: ```which mpirun```
-    If not, try full path: ```export PATH=/usr/lib64/openmpi/bin/mpirun\$PATH```

Alternative method for NRAO systems only

  • contact the helpdesk to install casa-toolset-3 (which contains the previous libraries)

  • the run export PATH=/opt/casa/03/bin:\$PATH

Note

Using the modular CASA Viewer with Mac OS requires a special setup step. Download and expand the pgplot installation files on your machine. Then set the following environment variables from a terminal:

export PGPLOT_DIR=<download location>/pgplot
export PGPLOT_FONT=<download location>/pgplot/grfont

Monolithic Distribution

On Linux:

  1. Download the .tar file and place it in a work directory (e.g. ~/casa)

  2. From a Linux terminal window:

    $: tar -xvf casa-xyz.tar.xz
    $: ./casa-xyz/bin/casa
    

The one caveat is that CASA on Linux currently will not run if the Security-Enhanced Linux option of the linux operating system is set to enforcing. For the non-root install to work, SElinux must be set to disabled or permissive (in /etc/selinux/config) or you must run (as root): $: setsebool -P allow_execheap=1. Otherwise, you will encounter errors like:

error while loading shared libraries: /opt/casa/casa-20.0.5653-001/lib/liblapack.so.3.1.1: cannot restore segment prot after reloc: Permission denied

WARNING: By default, python 3.6 (and earlier versions of python 3) include the current working directory in the python path at startup. Any script in that directory with the same name as a standard python module or a CASA module will be detected and used by python instead of the code that is delivered with CASA. Protections have been included for files called “new.py” and “pickle.py”, but other scripts may cause problems with the CASA startup. For example, do not include a file named runpy.py in the working directory.

On Macintosh:

  1. Download the .dmg disk image file

  2. Double click on the disk image file (if your browser does not automatically open it).

  3. Drag the CASA application to the Applications folder of your hard disk.

  4. Eject the CASA disk image.

  5. Double click the CASA application to run it for the first time. If the OS does not allow you to install apps from non-Apple sources, please Change the settings in “System Preferences-> Security & Privacy -> General” and “Allow applications downloaded from: Mac App store and identified developers”.

  6. Optional: Create symbolic links to the CASA version and its executables (Administrator privileges are required), which will allow you to run casa, casaviewer, casaplotms, etc. from any terminal command line. To do so, run !create-symlinks

Modular Packages

Pip wheels for casatools and casatasks are available as Python 3 modules. This allows simple installation and import into standard Python environments. The casatools wheel is necessarily a binary wheel so there may be some compatibility issues for some time as we work toward making wheels available for important Python configurations.

Make sure you have set up your machine with the necessary prerequisite libraries first. Then a la carte installation of desired modules (from a Linux terminal window) as follows:

$: python3.8 -m venv myvenv
$: source myvenv/bin/activate
(myvenv) $: pip install --upgrade pip wheel

Note: for the Python 3.10 version, instead use: $: python3.10 -m venv myvenv

Now pick whichever subset of the available CASA packages you are interested in. Package dependencies are handled automatically by pip, with the exception of casadata which must be explicitly installed and updated by the user (see External Data). The following packages are available:

(myvenv) $: pip install casatools==6.6.4.34
(myvenv) $: pip install casatasks==6.6.4.34
(myvenv) $: pip install casaplotms==2.4.3
(myvenv) $: pip install casaviewer==2.1.4
(myvenv) $: pip install casashell==6.6.4.34
(myvenv) $: pip install casaplotserver==1.8.2
(myvenv) $: pip install almatasks==1.7.1
(myvenv) $: pip install casatestutils==6.6.4.34
(myvenv) $: pip install casatablebrowser==0.0.35
(myvenv) $: pip install casalogger==1.0.19
(myvenv) $: pip install casafeather==0.0.22
(myvenv) $: pip install casampi==0.5.5

Note for Mac M1 users: For MacOS on an ARM-based M1/M2/M3 chip, users will need to (1) install the Rosetta software, (2) have a Python interpreter with universal support, (3) install the CASA wheels for x86 architecture. For the latter, users need to precede all the pip commands with “arch -x86_64”, for example:

$: arch -x86_64 python3.10 -m venv myvenv
and
(myvenv) $: arch -x86_64 python3 -m pip install ...

Users are advised to use a Python virtual environment (venv) and specific module version numbers as shown above. Giving a blank (or invalid) number to the pip install command is an effective way to list all available version numbers.

List all available versions of a module (a hack):

(myvenv) $: pip install casatasks==
ERROR: Could not find a version that satisfies the requirement casatasks== (from versions: 6.0.0.27, 6.2.0.124, 6.2.1.7, 6.3.0.48, 6.4.0.16, 6.4.3.27, 6.4.4.31, 6.5.0.15, 6.5.1.23, 6.5.2.26, 6.5.3.28, 6.5.5.20, 6.5.5.21, 6.5.6.21, 6.5.6.22, 6.6.0.19, 6.6.0.20, 6.6.3.22)

Start Python in your venv and sanity check:

(myvenv) $ python

Python 3.6.9 (default, Nov 7 2019, 10:44:02)
[[GCC 8.3.0] on linux]
Type "help", "copyright", "credits" or "license" for more information.
>>> import casatasks
>>> help(casatasks)

To exit the python venv, type deactivate from the terminal. However, the rest of this documentation assumes the venv is active (to reactivate, type source myvenv/bin/activate)

The use of python3 venv is a simple built-in method of containerizing the pip install such that multiple versions of CASA 6.x can be kept on a single machine in different environments. In addition, CASA is built and tested using standard (python 3.6) libraries which can be replicated with a fresh venv, keeping the libraries needed for CASA isolated from other libraries which may already be installed on your machine.

With the pip installation, CASA may be used in a standard Pythonic manner. Examples can be found in this Jupyter Notebook.

WARNING: The pip-wheel version is intended for manual data processing, and is not yet officially endorsed by ALMA or VLA. Currently, pipelines are included in -and tested only for- all-inclusive monolithic CASA distributions.

Parallel Processing Setup

The casampi package provides the task-level MPI parallelization infrastructure of CASA. The casatasks module detects when casampi is available and enables the parallel processing capabilities of CASA. Advanced users may also access the casampi package directly to build new or custom parallelization schemes.

Make sure you have installed the prerequisite OS libraries for parallel processing. In particular, users should have mpicc installed, and then follow these general instructions for installing mpi4py: https://mpi4py.readthedocs.io/en/stable/install.html

To test for correct modular MPI installation, run the following commands (from Linux terminal):

(myvenv) $ echo "from casampi.MPIEnvironment import MPIEnvironment; print('working?', MPIEnvironment.is_mpi_enabled)" > test.py
(myvenv) $ mpirun -q -n 2 python test.py

observe two instances of “working? True”

Installation Tests

CASA provides a test script to verify the installation of CASA in the user’s system. The script will download testdata from the CASA git repository on-the-fly and run 14 test cases to verify the execution of some casatasks. The following are some pre-requisites to run the installation tests in your system.

  • Working directory needs to have read/write permissions

  • System needs to be connected to the internet to download testdata

  • System needs to have git-lfs installed for the data download

  • When installing modular CASA, the minimum set of packages to install are casatasks, casatestutils and casadata.

Follow the instructions to install CASA for a monolithic distribution and run the test_casatasks.py script which is installed in the site-packages of your CASA installation. The example below shows running the test script from the command-line using a CASA monolithic installation in Linux.

./casa-xyz/bin/casa -c ./casa-xyz/lib/py/lib/python3.8/site-packages/casatasks/tests/test_casatasks.py

For Mac OS, the command-line input is as follows:

./casa_xyz.app/Contents/darwin/bin/casa -c ./casa_xyz.app/Contents/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/casatasks/tests/test_casatasks.py

For testing the installation of modular CASA, follow the installation steps, and then point python to the test script as in:

python3 ./venv/lib/python3.8/site-packages/casatasks/tests/test_casatasks.py

Performance

CASA is now running performance benchmarks against a subset of the casatasks API to track various runtime metrics over development history of the project, starting in CASA 6. See the Performance Benchmark webpages for an interactive view of the latest test results.

casabench

The tests are implemented using airspeed-velocity with configuration and results tracked by a separate repository. Automated deployment is coordinated with Bamboo and confined to a single computer node.

The dedicated testing machine has eight Intel(R) Xeon(R) CPUs (E5-2670 @ 2.60GHz), 264GB of DDR3 SDRAM (36KSF2G72PZ-1G6P1 @ 1600 MT/s), 500GB Crucial(R) internal SSD (MX500), and runs Red Hat Enterprise Linux Workstation release 7.9 against the Linux kernel version 3.10.0-1160.71.1.el7.x86_64.

Tests currently run for each CASA6 pre-release package once other verification steps are complete. New tests and test cases will be added as development continues in CASA.