Why are flux scaling and restoring beam calculations in CASA 3.4, 4.0, 4.1 task clean incorrect when selecting field by name and field name ends in a minus?
08 July 2013 02:15 PM
This is to notify all CASA users that a bug was dicovered in the code underlying the field selection mechanism in the clean task. The bug is present in CASA 3.4, 4.0, and 4.1 and affects the flux scaling and restoring beam calculations in clean.
This bug is triggered only when:
a) selection is done by field name (rather than ID),
b) there are other fields besides the selected one in the MeasurementSet (MS),
c) the field name contains a "-" (minus) as one of the last two characters.
E.g. the selection
field = 'SgrB-1'
would cause the problem if there were other fields contained in the MS.
When the above three conditions are fulfilled, the image may still look OK, but the primary beam and the flux scaling of the image may be incorrect. Flux scale differences up to 40% were seen. The underlying cause is a bug in the string handling which is fixed now. The fix was included in the August 4.2.0 stable release of CASA (r26184), the full 4.2 release (r28322) and all subsequent releases.
The workaround is to simply not select by field name but by field ID. You can find the correct ID of each field by looking at the output of the listobs task.