Sunspot Band6 Calibration for CASA 6.5.4
Last checked on CASA Version 6.5.4
Getting Started
Details of these ALMA observations are provided at Sunspot_Band6. This portion of the guide will cover the calibration of the raw visibility data.
WARNING: The command in the #Tsys+Tant calibration of the Sun section of this guide takes a long time to run, about one night or day.
Download and Unpack the Data
To follow this guide you must download the file Sunspot_Band6_UncalibratedData.tgz from Sunspot_Band6#Obtaining the Data.
Unpack and cd to the directory:
#In bash
tar -xvzf Sunspot_Band6_UncalibratedData.tgz
cd Sunspot_Band6_UncalibratedData
Confirm your version of CASA
This guide has been written for CASA release 6.5. Start CASA and confirm your version before proceeding.
# In CASA
from casatools import version
vernum = str(version()[0])+'.'+str(version()[1])
print("You are using CASA ver. "+vernum)
if float(vernum) < 6.5:
print("YOUR VERSION OF CASA IS TOO OLD FOR THIS GUIDE.")
print("PLEASE UPDATE IT BEFORE PROCEEDING.")
else:
print("Your version of CASA is appropriate for this guide.")
Import Tools and Scripts
The "Analysis Utilities" package must be used for the calibration of raw solar visibility data. Therefore, before starting the tutorial, you need to import the package to your data-analysis environment. The documents and software of the package can be obtained from the Analysis_Utilities guide.
We also need script to download the script Sun_reduction_util_6.5.4.py and execute it inside our CASA session.
#In CASA
import analysisUtils as aU
es = aU.stuffForScienceDataReduction()
execfile('Sun_reduction_util_6.5.4.py')
Initial Inspection
Import the Data into CASA
We start by defining the directory name of the ASDM and some directory names of the Measurement Sets (MS) for the calibration.
#In CASA
asdm ='uid___A002_Xae00c5_X2a8d'
mso = asdm + '.ms' #MS original
mss = asdm + '.ms.split' #MS split
msc = asdm + '.ms.split.cal' #MS calibrated
The raw data have been provided to you in the ASDM format. It is the native format of the data produced by the ALMA observatory.
Before we can proceed to the calibration, we will need to convert those data to the CASA MS format. This is done simply with the task importasdm.
#In CASA
importasdm(asdm=asdm, vis=mso, asis='Antenna Station Receiver Source CalAtmosphere CalWVR CorrelatorMode SBSummary CalDevice')
To fix the bug in the SYSCAL table times, the following commands are executed.
#In CASA
from casarecipes.almahelpers import fixsyscaltimes
fixsyscaltimes(vis=mso)
Inspect the Data
The usual first step is then to get some basic information about the data. We do this using the task listobs, which will output a detailed summary of each dataset supplied.
#In CASA
listobs(mso, listfile=asdm+'.listobs.txt')
The output will be sent to the CASA logger, or saved in a text file.
- The first section shows information about the project and observing time:
Observer: shimojo Project: uid://A002/Xac494e/X3 Observation: ALMA Data records: 20923884 Total elapsed time = 3184.8 seconds Observed from 18-Dec-2015/19:15:42.3 to 18-Dec-2015/20:08:47.1 (UTC)
Scan List
- The second section describes details of each scan. This is often easier to read in a text viewer with line wrapping turned off. We see that our Fields have the following associated intents:
- Field 0 = Sun: observed for the measurement of zero-signal level [scan 1] and the calibration of atmosphere [scans 10,13,16]. Scientific observations of the Sun (Target) [scans 11,14,17] are listed many times, which represent a mosaic.
- Field 1 = J1924-2914: observed for the calibrations of pointing [scan 2], sideband ratio [scan 3], atmosphere [scan 4], and bandpass [scan 5]
- Field 2 = nrao530: observed for the calibration of pointing [scan 6], atmosphere [scan 7], flux [scan 8], and phase [scans 9,12,15,18]
ObservationID = 0 ArrayID = 0 Date Timerange (UTC) Scan FldId FieldName nRows SpwIds Average Interval(s) ScanIntent 18-Dec-2015/19:15:42.3 - 19:16:47.5 1 0 Sun 236530 [0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.016, 0.016, 0.016, 0.016, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_ATMOSPHERE#REFERENCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE,CALIBRATE_WVR#REFERENCE] 19:17:31.8 - 19:19:26.4 2 1 J1924-2914 1081497 [4,25,26,27,28,29,30,31,32,33,34,35,36] [1.15, 0.016, 0.016, 0.016, 0.016, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_POINTING#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:20:14.2 - 19:21:17.7 3 1 J1924-2914 895435 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_SIDEBAND_RATIO#IMAGE,CALIBRATE_SIDEBAND_RATIO#SIGNAL,CALIBRATE_WVR#IMAGE,CALIBRATE_WVR#SIGNAL] 19:22:06.0 - 19:22:23.1 4 1 J1924-2914 177382 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE] 19:23:11.6 - 19:28:27.9 5 1 J1924-2914 3244522 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_BANDPASS#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:29:14.5 - 19:31:09.2 6 2 nrao530 1081528 [4,25,26,27,28,29,30,31,32,33,34,35,36] [1.15, 0.016, 0.016, 0.016, 0.016, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_POINTING#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:31:54.6 - 19:32:11.4 7 2 nrao530 177413 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE] 19:32:59.1 - 19:35:36.6 8 2 nrao530 1622261 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_FLUX#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:36:21.9 - 19:36:52.1 9 2 nrao530 324446 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_PHASE#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:37:41.4 - 19:37:57.8 10 0 Sun 177413 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE] 19:39:23.9 - 19:49:36.0 11 0 Sun 3760610 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#OFF_SOURCE,CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#OFF_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:39:23.9 - 19:49:36.0 11 3 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:39:23.9 - 19:49:36.0 11 4 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:39:23.9 - 19:49:36.0 11 5 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] *** Scan 11, Fields 6~76 trimmed for brevity *** 19:39:23.9 - 19:49:36.0 11 77 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:39:23.9 - 19:49:36.0 11 78 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:39:23.9 - 19:49:36.0 11 79 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:50:21.7 - 19:50:52.0 12 2 nrao530 324446 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_PHASE#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 19:51:41.2 - 19:51:58.0 13 0 Sun 177413 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE] 19:53:26.0 - 20:03:37.0 14 0 Sun 3742537 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#OFF_SOURCE,CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#OFF_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 3 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 4 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 5 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 6 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 7 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 8 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 9 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 80 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 81 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 82 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] *** Scan 14, Fields 83~147 trimmed for brevity *** 19:53:26.0 - 20:03:37.0 14 148 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 149 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 19:53:26.0 - 20:03:37.0 14 150 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 20:04:22.7 - 20:04:53.7 15 2 nrao530 324446 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_PHASE#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] 20:05:43.3 - 20:06:00.2 16 0 Sun 177413 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576, 0.576] [CALIBRATE_ATMOSPHERE#AMBIENT,CALIBRATE_ATMOSPHERE#HOT,CALIBRATE_ATMOSPHERE#OFF_SOURCE,CALIBRATE_WVR#AMBIENT,CALIBRATE_WVR#HOT,CALIBRATE_WVR#OFF_SOURCE] 20:06:47.8 - 20:07:30.5 17 0 Sun 227168 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#OFF_SOURCE,CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#OFF_SOURCE,OBSERVE_TARGET#ON_SOURCE] 20:06:47.8 - 20:07:30.5 17 10 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 20:06:47.8 - 20:07:30.5 17 11 Sun 18042 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 20:06:47.8 - 20:07:30.5 17 12 Sun 18011 [4,5,6,7,8,9,10,11,12] [1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_WVR#ON_SOURCE,OBSERVE_TARGET#ON_SOURCE] 20:08:16.5 - 20:08:47.1 18 2 nrao530 324446 [0,1,2,3,4,5,6,7,8,9,10,11,12] [0.016, 0.016, 0.016, 0.016, 1.15, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01, 2.02, 1.01] [CALIBRATE_PHASE#ON_SOURCE,CALIBRATE_WVR#ON_SOURCE] (nRows = Total number of rows per scan)
Field List
- The third section shows the information of the observing targets. This shows that three Sources with 151 Fields were observed: The Sun, J1924-2914, and nrao530 (J1733-1304). The Sun as one Source has many Fields - this is how a mosaic is represented:
Fields: 151 ID Code Name RA Decl Epoch SrcId nRows 0 none Sun 17:44:04.359217 -23.19.29.92535 ICRS 0 8499084 1 none J1924-2914 19:24:51.055957 -29.14.30.12103 ICRS 1 5398836 2 none nrao530 17:33:02.705760 -13.04.49.54800 ICRS 2 4178986 3 none Sun 17:44:03.784899 -23.20.37.96258 ICRS 0 36022 4 none Sun 17:44:04.746002 -23.20.37.96880 ICRS 0 36053 5 none Sun 17:44:05.707104 -23.20.37.97466 ICRS 0 36053 6 none Sun 17:44:06.668207 -23.20.37.98018 ICRS 0 36053 7 none Sun 17:44:07.629310 -23.20.37.98535 ICRS 0 36053 8 none Sun 17:44:08.590412 -23.20.37.99016 ICRS 0 36022 9 none Sun 17:44:09.551515 -23.20.37.99463 ICRS 0 36022 10 none Sun 17:44:10.512617 -23.20.37.99875 ICRS 0 36022 11 none Sun 17:44:11.473720 -23.20.38.00251 ICRS 0 36053 12 none Sun 17:44:12.434823 -23.20.38.00593 ICRS 0 36053 13 none Sun 17:44:13.395926 -23.20.38.00900 ICRS 0 18011 14 none Sun 17:44:03.555941 -23.20.26.81043 ICRS 0 18011 15 none Sun 17:44:04.517022 -23.20.26.81682 ICRS 0 18011 16 none Sun 17:44:05.478102 -23.20.26.82286 ICRS 0 18011 17 none Sun 17:44:06.439183 -23.20.26.82855 ICRS 0 18042 18 none Sun 17:44:07.400264 -23.20.26.83389 ICRS 0 18011 19 none Sun 17:44:08.361345 -23.20.26.83888 ICRS 0 18042 20 none Sun 17:44:09.322425 -23.20.26.84352 ICRS 0 18011 21 none Sun 17:44:10.283506 -23.20.26.84781 ICRS 0 18011 22 none Sun 17:44:11.244587 -23.20.26.85175 ICRS 0 18011 23 none Sun 17:44:12.205668 -23.20.26.85534 ICRS 0 18011 24 none Sun 17:44:13.166748 -23.20.26.85858 ICRS 0 18042 25 none Sun 17:44:14.127829 -23.20.26.86147 ICRS 0 18011 26 none Sun 17:44:04.288064 -23.20.15.66473 ICRS 0 18011 27 none Sun 17:44:05.249123 -23.20.15.67095 ICRS 0 18011 28 none Sun 17:44:06.210181 -23.20.15.67681 ICRS 0 18011 29 none Sun 17:44:07.171240 -23.20.15.68232 ICRS 0 18042 30 none Sun 17:44:08.132299 -23.20.15.68749 ICRS 0 18011 31 none Sun 17:44:09.093358 -23.20.15.69230 ICRS 0 18042 32 none Sun 17:44:10.054417 -23.20.15.69676 ICRS 0 18011 33 none Sun 17:44:11.015475 -23.20.15.70087 ICRS 0 18011 34 none Sun 17:44:11.976534 -23.20.15.70464 ICRS 0 18011 35 none Sun 17:44:12.937593 -23.20.15.70805 ICRS 0 18011 36 none Sun 17:44:13.898652 -23.20.15.71111 ICRS 0 18042 37 none Sun 17:44:04.059128 -23.20.04.51254 ICRS 0 18011 38 none Sun 17:44:05.020164 -23.20.04.51893 ICRS 0 18011 39 none Sun 17:44:05.981201 -23.20.04.52496 ICRS 0 18011 40 none Sun 17:44:06.942238 -23.20.04.53065 ICRS 0 18011 41 none Sun 17:44:07.903275 -23.20.04.53598 ICRS 0 18042 42 none Sun 17:44:08.864312 -23.20.04.54097 ICRS 0 18011 43 none Sun 17:44:09.825349 -23.20.04.54560 ICRS 0 18042 44 none Sun 17:44:10.786386 -23.20.04.54989 ICRS 0 18011 45 none Sun 17:44:11.747423 -23.20.04.55382 ICRS 0 18011 46 none Sun 17:44:12.708460 -23.20.04.55741 ICRS 0 18011 47 none Sun 17:44:13.669497 -23.20.04.56064 ICRS 0 18011 48 none Sun 17:44:14.630534 -23.20.04.56353 ICRS 0 18042 49 none Sun 17:44:04.791228 -23.19.53.36679 ICRS 0 18011 50 none Sun 17:44:05.752243 -23.19.53.37300 ICRS 0 18011 51 none Sun 17:44:06.713258 -23.19.53.37886 ICRS 0 18011 52 none Sun 17:44:07.674273 -23.19.53.38437 ICRS 0 18011 53 none Sun 17:44:08.635288 -23.19.53.38953 ICRS 0 18042 54 none Sun 17:44:09.596303 -23.19.53.39433 ICRS 0 18011 55 none Sun 17:44:10.557318 -23.19.53.39879 ICRS 0 18042 56 none Sun 17:44:11.518333 -23.19.53.40290 ICRS 0 18011 57 none Sun 17:44:12.479348 -23.19.53.40666 ICRS 0 18011 58 none Sun 17:44:13.440364 -23.19.53.41007 ICRS 0 18011 59 none Sun 17:44:14.401379 -23.19.53.41312 ICRS 0 18011 60 none Sun 17:44:04.562314 -23.19.42.21455 ICRS 0 18042 61 none Sun 17:44:05.523307 -23.19.42.22093 ICRS 0 18011 62 none Sun 17:44:06.484300 -23.19.42.22696 ICRS 0 18011 63 none Sun 17:44:07.445293 -23.19.42.23264 ICRS 0 18011 64 none Sun 17:44:08.406286 -23.19.42.23797 ICRS 0 18011 65 none Sun 17:44:09.367280 -23.19.42.24295 ICRS 0 18042 66 none Sun 17:44:10.328273 -23.19.42.24758 ICRS 0 18011 67 none Sun 17:44:11.289266 -23.19.42.25187 ICRS 0 18042 68 none Sun 17:44:12.250259 -23.19.42.25580 ICRS 0 18011 69 none Sun 17:44:13.211252 -23.19.42.25938 ICRS 0 18011 70 none Sun 17:44:14.172245 -23.19.42.26261 ICRS 0 18011 71 none Sun 17:44:15.133239 -23.19.42.26549 ICRS 0 18011 72 none Sun 17:44:05.294393 -23.19.31.06875 ICRS 0 18042 73 none Sun 17:44:06.255364 -23.19.31.07495 ICRS 0 18011 74 none Sun 17:44:07.216335 -23.19.31.08081 ICRS 0 18011 75 none Sun 17:44:08.177306 -23.19.31.08631 ICRS 0 18011 76 none Sun 17:44:09.138278 -23.19.31.09146 ICRS 0 18011 77 none Sun 17:44:11.060220 -23.19.31.10072 ICRS 0 18011 78 none Sun 17:44:12.021191 -23.19.31.10482 ICRS 0 18042 79 none Sun 17:44:12.982163 -23.19.31.10858 ICRS 0 18011 80 none Sun 17:44:14.662815 -23.19.31.26419 ICRS 0 18042 81 none Sun 17:44:15.623787 -23.19.31.26724 ICRS 0 18011 82 none Sun 17:44:05.785179 -23.19.20.06866 ICRS 0 18042 83 none Sun 17:44:06.746129 -23.19.20.07503 ICRS 0 18011 84 none Sun 17:44:07.707078 -23.19.20.08105 ICRS 0 18011 85 none Sun 17:44:08.668028 -23.19.20.08672 ICRS 0 18011 86 none Sun 17:44:09.628977 -23.19.20.09204 ICRS 0 18011 87 none Sun 17:44:10.589927 -23.19.20.09701 ICRS 0 18042 88 none Sun 17:44:11.550877 -23.19.20.10163 ICRS 0 18011 89 none Sun 17:44:12.511827 -23.19.20.10590 ICRS 0 18011 90 none Sun 17:44:13.472776 -23.19.20.10982 ICRS 0 18011 91 none Sun 17:44:14.433726 -23.19.20.11339 ICRS 0 18011 92 none Sun 17:44:15.394676 -23.19.20.11661 ICRS 0 18042 93 none Sun 17:44:16.355625 -23.19.20.11948 ICRS 0 18011 94 none Sun 17:44:06.517236 -23.19.08.92273 ICRS 0 18042 95 none Sun 17:44:07.478164 -23.19.08.92892 ICRS 0 18011 96 none Sun 17:44:08.439092 -23.19.08.93476 ICRS 0 18011 97 none Sun 17:44:09.400019 -23.19.08.94026 ICRS 0 18011 98 none Sun 17:44:10.360947 -23.19.08.94540 ICRS 0 18011 99 none Sun 17:44:11.321875 -23.19.08.95019 ICRS 0 18042 100 none Sun 17:44:12.282803 -23.19.08.95464 ICRS 0 18011 101 none Sun 17:44:13.243731 -23.19.08.95873 ICRS 0 18011 102 none Sun 17:44:14.204658 -23.19.08.96247 ICRS 0 18011 103 none Sun 17:44:15.165586 -23.19.08.96587 ICRS 0 18011 104 none Sun 17:44:16.126514 -23.19.08.96891 ICRS 0 18042 105 none Sun 17:44:06.288366 -23.18.57.77032 ICRS 0 18011 106 none Sun 17:44:07.249271 -23.18.57.77669 ICRS 0 18042 107 none Sun 17:44:08.210177 -23.18.57.78270 ICRS 0 18011 108 none Sun 17:44:09.171083 -23.18.57.78837 ICRS 0 18011 109 none Sun 17:44:10.131989 -23.18.57.79368 ICRS 0 18011 110 none Sun 17:44:11.092895 -23.18.57.79865 ICRS 0 18011 111 none Sun 17:44:12.053801 -23.18.57.80326 ICRS 0 18042 112 none Sun 17:44:13.014707 -23.18.57.80753 ICRS 0 18011 113 none Sun 17:44:13.975613 -23.18.57.81145 ICRS 0 18011 114 none Sun 17:44:14.936519 -23.18.57.81501 ICRS 0 18011 115 none Sun 17:44:15.897425 -23.18.57.81823 ICRS 0 18011 116 none Sun 17:44:16.858331 -23.18.57.82110 ICRS 0 18042 117 none Sun 17:44:07.020401 -23.18.46.62434 ICRS 0 18011 118 none Sun 17:44:07.981285 -23.18.46.63053 ICRS 0 18042 119 none Sun 17:44:08.942169 -23.18.46.63637 ICRS 0 18011 120 none Sun 17:44:09.903053 -23.18.46.64185 ICRS 0 18011 121 none Sun 17:44:10.863937 -23.18.46.64699 ICRS 0 18011 122 none Sun 17:44:11.824821 -23.18.46.65178 ICRS 0 18011 123 none Sun 17:44:12.785705 -23.18.46.65622 ICRS 0 18042 124 none Sun 17:44:13.746589 -23.18.46.66031 ICRS 0 18011 125 none Sun 17:44:14.707473 -23.18.46.66405 ICRS 0 18011 126 none Sun 17:44:15.668357 -23.18.46.66744 ICRS 0 18011 127 none Sun 17:44:16.629241 -23.18.46.67048 ICRS 0 18011 128 none Sun 17:44:06.791552 -23.18.35.47189 ICRS 0 18042 129 none Sun 17:44:07.752414 -23.18.35.47825 ICRS 0 18011 130 none Sun 17:44:08.713276 -23.18.35.48426 ICRS 0 18042 131 none Sun 17:44:09.674116 -23.18.35.48972 ICRS 0 18011 132 none Sun 17:44:10.634936 -23.18.35.49465 ICRS 0 18011 133 none Sun 17:44:11.595756 -23.18.35.49924 ICRS 0 18011 134 none Sun 17:44:12.556576 -23.18.35.50347 ICRS 0 18011 135 none Sun 17:44:13.517396 -23.18.35.50736 ICRS 0 18042 136 none Sun 17:44:14.478216 -23.18.35.51089 ICRS 0 18011 137 none Sun 17:44:15.439036 -23.18.35.51408 ICRS 0 18011 138 none Sun 17:44:16.399856 -23.18.35.51691 ICRS 0 18011 139 none Sun 17:44:17.360676 -23.18.35.51940 ICRS 0 18011 140 none Sun 17:44:07.523164 -23.18.24.32227 ICRS 0 18042 141 none Sun 17:44:08.483962 -23.18.24.32807 ICRS 0 18011 142 none Sun 17:44:09.444760 -23.18.24.33353 ICRS 0 18042 143 none Sun 17:44:10.405558 -23.18.24.33864 ICRS 0 18011 144 none Sun 17:44:11.366356 -23.18.24.34339 ICRS 0 18011 145 none Sun 17:44:12.327154 -23.18.24.34780 ICRS 0 18011 146 none Sun 17:44:13.287952 -23.18.24.35186 ICRS 0 18011 147 none Sun 17:44:14.248750 -23.18.24.35557 ICRS 0 18042 148 none Sun 17:44:15.209549 -23.18.24.35893 ICRS 0 18011 149 none Sun 17:44:16.170347 -23.18.24.36194 ICRS 0 18011 150 none Sun 17:44:17.131145 -23.18.24.36460 ICRS 0 18011
Spectral Window List
- The fourth section shows the information of the spws in the dataset. From the scan list, we see that science (Target) scans are done with the spw 0~12. Of these, the spws with 128 channels are 5,7,9,11, which are used for image synthesis. Therefore, we will apply calibrations to spws 5,7,9,11 only. The data of spws 0,1,2,3 are the data from the square-law detectors of the basebands, which will be used for creating Tsys+Tant tables, and are archived as the auto-correlation data in the dataset.
Spectral Windows: (37 unique spectral windows and 2 unique polarization setups) SpwID Name #Chans Frame Ch0(MHz) ChanWid(kHz) TotBW(kHz) CtrFreq(MHz) BBC Num Corrs 0 BB_1#SQLD 1 TOPO 230000.000 2000000.000 2000000.0 230000.0000 1 XX YY 1 BB_2#SQLD 1 TOPO 232000.000 2000000.000 2000000.0 232000.0000 2 XX YY 2 BB_3#SQLD 1 TOPO 246000.000 2000000.000 2000000.0 246000.0000 3 XX YY 3 BB_4#SQLD 1 TOPO 248000.000 2000000.000 2000000.0 248000.0000 4 XX YY 4 WVR#NOMINAL 4 TOPO 184550.000 1500000.000 7500000.0 187550.0000 0 XX 5 X241538345#ALMA_RB_06#BB_1#SW-01#FULL_RES 128 TOPO 230992.188 -15625.000 2000000.0 230000.0000 1 XX YY 6 X241538345#ALMA_RB_06#BB_1#SW-01#CH_AVG 1 TOPO 229984.375 1796875.000 1796875.0 229984.3750 1 XX YY 7 X241538345#ALMA_RB_06#BB_2#SW-01#FULL_RES 128 TOPO 232992.188 -15625.000 2000000.0 232000.0000 2 XX YY 8 X241538345#ALMA_RB_06#BB_2#SW-01#CH_AVG 1 TOPO 231984.375 1796875.000 1796875.0 231984.3750 2 XX YY 9 X241538345#ALMA_RB_06#BB_3#SW-01#FULL_RES 128 TOPO 245007.813 15625.000 2000000.0 246000.0000 3 XX YY 10 X241538345#ALMA_RB_06#BB_3#SW-01#CH_AVG 1 TOPO 245984.375 1796875.000 1796875.0 245984.3750 3 XX YY 11 X241538345#ALMA_RB_06#BB_4#SW-01#FULL_RES 128 TOPO 247007.813 15625.000 2000000.0 248000.0000 4 XX YY 12 X241538345#ALMA_RB_06#BB_4#SW-01#CH_AVG 1 TOPO 247984.375 1796875.000 1796875.0 247984.3750 4 XX YY 13 BB_1#SQLD 1 TOPO 219559.000 2000000.000 2000000.0 219559.0000 1 XX YY 14 BB_2#SQLD 1 TOPO 219559.000 2000000.000 2000000.0 219559.0000 2 XX YY 15 BB_3#SQLD 1 TOPO 219559.000 2000000.000 2000000.0 219559.0000 3 XX YY 16 BB_4#SQLD 1 TOPO 219559.000 2000000.000 2000000.0 219559.0000 4 XX YY 17 X241538345#ALMA_RB_06#BB_1#SW-01#FULL_RES 128 TOPO 220551.188 -15625.000 2000000.0 219559.0000 1 XX YY 18 X241538345#ALMA_RB_06#BB_1#SW-01#CH_AVG 1 TOPO 219543.375 1796875.000 1796875.0 219543.3750 1 XX YY 19 X241538345#ALMA_RB_06#BB_2#SW-01#FULL_RES 128 TOPO 220551.188 -15625.000 2000000.0 219559.0000 2 XX YY 20 X241538345#ALMA_RB_06#BB_2#SW-01#CH_AVG 1 TOPO 219543.375 1796875.000 1796875.0 219543.3750 2 XX YY 21 X241538345#ALMA_RB_06#BB_3#SW-01#FULL_RES 128 TOPO 220551.188 -15625.000 2000000.0 219559.0000 3 XX YY 22 X241538345#ALMA_RB_06#BB_3#SW-01#CH_AVG 1 TOPO 219543.375 1796875.000 1796875.0 219543.3750 3 XX YY 23 X241538345#ALMA_RB_06#BB_4#SW-01#FULL_RES 128 TOPO 220551.188 -15625.000 2000000.0 219559.0000 4 XX YY 24 X241538345#ALMA_RB_06#BB_4#SW-01#CH_AVG 1 TOPO 219543.375 1796875.000 1796875.0 219543.3750 4 XX YY 25 BB_1#SQLD 1 TOPO 221538.000 2000000.000 2000000.0 221538.0000 1 XX YY 26 BB_2#SQLD 1 TOPO 223538.000 2000000.000 2000000.0 223538.0000 2 XX YY 27 BB_3#SQLD 1 TOPO 237538.000 2000000.000 2000000.0 237538.0000 3 XX YY 28 BB_4#SQLD 1 TOPO 239538.000 2000000.000 2000000.0 239538.0000 4 XX YY 29 X0000000000#ALMA_RB_06#BB_1#SW-01#FULL_RES 128 TOPO 222530.188 -15625.000 2000000.0 221538.0000 1 XX YY 30 X0000000000#ALMA_RB_06#BB_1#SW-01#CH_AVG 1 TOPO 221514.562 1781250.000 1781250.0 221514.5625 1 XX YY 31 X0000000000#ALMA_RB_06#BB_2#SW-01#FULL_RES 128 TOPO 224530.188 -15625.000 2000000.0 223538.0000 2 XX YY 32 X0000000000#ALMA_RB_06#BB_2#SW-01#CH_AVG 1 TOPO 223514.562 1781250.000 1781250.0 223514.5625 2 XX YY 33 X0000000000#ALMA_RB_06#BB_3#SW-01#FULL_RES 128 TOPO 236545.813 15625.000 2000000.0 237538.0000 3 XX YY 34 X0000000000#ALMA_RB_06#BB_3#SW-01#CH_AVG 1 TOPO 237514.563 1781250.000 1781250.0 237514.5625 3 XX YY 35 X0000000000#ALMA_RB_06#BB_4#SW-01#FULL_RES 128 TOPO 238545.813 15625.000 2000000.0 239538.0000 4 XX YY 36 X0000000000#ALMA_RB_06#BB_4#SW-01#CH_AVG 1 TOPO 239514.563 1781250.000 1781250.0 239514.5625 4 XX YY
- The fifth sections lists the spectral windows (spws) used for each Source. We exclude this for brevity.
Antenna List
- The sixth section shows antenna information. Thirty-one antennas were used for the dataset. Note that numbering in python always begins with "0", so the antennas have IDs 0-30. To see what the antenna configuration looked like at the time of this observation, we use the task plotants (Figure 1):
Antennas: 31: ID Name Station Diam. Long. Lat. Offset from array center (m) ITRF Geocentric coordinates (m) East North Elevation x y z 0 CM01 N602 7.0 m -067.45.17.4 -22.53.22.3 8.8042 -527.8587 22.2034 2225080.354846 -5440132.955920 -2481524.789784 1 CM02 J502 7.0 m -067.45.17.7 -22.53.23.0 2.1073 -549.4461 22.1460 2225070.957857 -5440127.670516 -2481544.655003 2 CM03 J503 7.0 m -067.45.17.4 -22.53.23.2 9.2482 -555.0637 22.1304 2225076.734430 -5440122.931505 -2481549.824201 3 CM06 N606 7.0 m -067.45.17.1 -22.53.23.6 19.1995 -566.5684 22.1011 2225084.240492 -5440114.997537 -2481560.411621 4 CM07 N601 7.0 m -067.45.17.0 -22.53.22.5 21.0633 -532.5817 22.1865 2225090.999805 -5440126.600430 -2481529.134327 5 CM08 J505 7.0 m -067.45.18.0 -22.53.22.8 -7.2123 -541.3466 22.1685 2225063.532652 -5440134.133528 -2481537.202006 6 CM09 N603 7.0 m -067.45.17.7 -22.53.22.3 -0.0497 -527.8657 22.1913 2225072.154896 -5440136.294753 -2481524.791487 7 CM10 J501 7.0 m -067.45.17.4 -22.53.22.9 10.0863 -545.4959 22.1606 2225078.929507 -5440126.084513 -2481541.021572 8 CM11 N604 7.0 m -067.45.17.8 -22.53.23.7 -0.2657 -571.8966 22.0829 2225065.433709 -5440120.432522 -2481565.313207 9 DA41 A004 12.0 m -067.45.15.9 -22.53.28.0 52.6609 -704.4171 21.7726 2225094.796703 -5440052.421785 -2481687.277348 10 DA49 A002 12.0 m -067.45.16.3 -22.53.27.6 40.6333 -690.2503 21.8023 2225085.761255 -5440062.100754 -2481674.237730 11 DA50 A038 12.0 m -067.45.18.5 -22.53.29.4 -22.4285 -745.7518 22.0606 2225019.312629 -5440066.210860 -2481725.468896 12 DA52 A018 12.0 m -067.45.17.2 -22.53.28.1 16.8264 -706.6065 21.7531 2225061.301483 -5440065.182346 -2481689.286759 13 DA54 A005 12.0 m -067.45.14.8 -22.53.28.7 83.3315 -725.0764 21.7237 2225120.123751 -5440033.331382 -2481706.290680 14 DA55 A047 12.0 m -067.45.16.4 -22.53.30.3 38.4542 -775.2187 21.5966 2225071.160250 -5440032.158745 -2481752.434689 15 DA57 A025 12.0 m -067.45.18.7 -22.53.27.4 -26.4296 -685.5228 22.2053 2225024.528985 -5440089.533369 -2481670.039352 16 DA59 A001 12.0 m -067.45.16.9 -22.53.27.7 24.1880 -693.3966 21.7925 2225070.073933 -5440067.185105 -2481677.132442 17 DA61 A006 12.0 m -067.45.15.0 -22.53.28.0 79.0341 -702.0939 21.7778 2225119.549746 -5440043.278703 -2481685.139167 18 DA62 A035 12.0 m -067.45.16.6 -22.53.28.1 32.0366 -706.8051 21.7640 2225075.353584 -5440059.362225 -2481689.473934 19 DA63 A039 12.0 m -067.45.18.0 -22.53.29.6 -6.1070 -751.7850 22.0696 2225033.533416 -5440057.867935 -2481731.030436 20 DA65 A030 12.0 m -067.45.18.1 -22.53.27.2 -10.3876 -679.1070 21.8267 2225040.189208 -5440085.447750 -2481663.981462 21 DV02 A007 12.0 m -067.45.15.1 -22.53.27.3 74.0140 -681.2928 21.3255 2225117.808983 -5440052.282474 -2481665.800190 22 DV07 A027 12.0 m -067.45.19.0 -22.53.28.7 -35.0460 -726.6032 21.5989 2225010.293430 -5440077.487712 -2481707.648731 23 DV11 A049 12.0 m -067.45.14.6 -22.53.29.6 88.4465 -754.5446 20.1464 2225119.968124 -5440019.440510 -2481732.824666 24 DV12 A017 12.0 m -067.45.15.9 -22.53.26.8 51.3634 -665.5893 21.3604 2225099.169786 -5440066.540560 -2481651.346952 25 DV13 A064 12.0 m -067.45.14.7 -22.53.31.4 85.6567 -808.0278 21.0176 2225109.813656 -5440001.983403 -2481782.434609 26 DV17 A031 12.0 m -067.45.19.1 -22.53.27.1 -37.8149 -675.5186 21.7325 2225015.299768 -5440097.041914 -2481660.638998 27 DV18 A009 12.0 m -067.45.16.1 -22.53.26.1 48.2542 -644.4621 21.0152 2225099.282791 -5440075.029589 -2481631.749120 28 DV20 A033 12.0 m -067.45.19.4 -22.53.29.0 -47.3621 -735.6360 21.8836 2224997.663712 -5440079.140555 -2481716.080921 29 DV22 A014 12.0 m -067.45.15.1 -22.53.26.4 74.5090 -654.2102 20.9880 2225122.137554 -5440061.557701 -2481640.719077 30 DV23 A003 12.0 m -067.45.16.5 -22.53.27.0 35.5295 -672.6352 21.3390 2225083.469962 -5440069.979758 -2481657.829615
Now let's plot the antennas with plotants:
# In CASA
plotants(vis=mso, figfile='plotants.png')
Flagging Unnecessary Data
Some scans in the data were used by the online system for pointing and sideband ratio calibration. These scans are no longer needed, and we can flag them easily with flagdata by selecting on 'intent'.
#In CASA
flagdata(vis=mso, mode='manual', intent='*POINTING*,*SIDEBAND_RATIO*', flagbackup=False)
The averaged data of each spectrum window is not used, so we flagged the averaged data as a follow.
#In CASA
flagdata(vis=mso, mode='manual', spw='6,8,10,12', flagbackup=False)
We will then store the current flagging state for each dataset using the flagmanager:
#In CASA
flagmanager(vis=mso, mode='save', versionname='priori1')
A priori calibration
Tsys calibration of the calibrators
The System Temperature (Tsys) calibration gives a first-order correction for the atmospheric opacity as a function of time and frequency, and associates weights with each visibility that persist through imaging. The MS dataset contains Tsys measurements; the task gencal is used to generate a calibration table. Since the dataset obtained with TDM, the data in the channels near the both edges of the spectrum window (~10 channels) are flagged with flagdata. The plots for checking are created by the checkCalTable subroutine of the Analysis Utilities package and saved to a new directory uid___A002_Xae00c5_X2a8d.ms.tsys.plots (Figure 2).
#In CASA
gencal(vis=mso, caltable=mso+'.tsys', caltype='tsys')
flagdata(vis=mso+'.tsys', mode='manual', spw='5:0~9;116~127,7:0~9;116~127,9:0~9;116~127,11:0~9;116~127', flagbackup=False)
es.checkCalTable(mso+'.tsys', msName=mso, interactive=False)
The Tsys of DA54 antennas are significant large, from the plot. In the later part, we will flag the data of the antenna. Please ignore the data of the scan #1, because the scan is not done for ATM cal. The scan is used for the measurement of zero-signal level .
We will apply the Tsys calibration table to the data of the calibrators with the task applycal, which reads the specified gain calibration tables, applies them to the (raw) data column, and writes the calibrated results into the corrected column. For non-solar observations, we also apply the WVR (Water Vapor Radiometer) calibration table to data. However, we must NOT apply the WVR table to the solar data, because the WVR receivers at the Sun are saturated. We apply the Tsys calibration table to the data of the bandpass calibrator:
#In CASA
applycal(vis=mso, field='1', spw='5,7,9,11', gaintable=mso+'.tsys', gainfield='1', interp='linear,linear', calwt=True, flagbackup=False)
In the observations, we do not the atmospheric calibration of the phase calibrator between the scientific scans, because a long suspension of scientific observations has a bad influence on science. Therefore, we apply the Tsys calibration table, which is created from the data of the atmosphere calibration at the flux calibrator or the Sun, to the phase calibrator, as follows.
#In CASA
applycal(vis=mso, field='2', spw='5,7,9,11', gaintable=mso+'.tsys', gainfield='2', interp='linear,linear', calwt=True, flagbackup=False)
You can use plotms to plot channel-averaged amplitudes as a function of time, comparing the DATA and CORRECTED columns after applying the Tsys correction. This way you can check that calibration has done what was expected, which is put the data onto the Kelvin temperature scale.
Tsys+Tant calibration of the Sun
The standard method of Tsys calibration cannot be applied to the data of the Sun, because the antenna temperature (Tant) of the Sun cannot be neglected for estimating the system equivalent flux density (SEFD). To estimate correct SEFD at the Sun, the solar observing sequence includes some special measurements, like the measurement of zero-signal level. The subroutines for creating and applying Tsys+Tant calibration tables are prepared by the ALMA solar development team. They are part of the script we executed in the section #Import Tools and Scripts. For the Tsys+Tant calibration of the solar data, you will execute only the following command:
#In CASA
sol_ampcal_2(mso, mso+'.tsys', exisTbl=False, outCSV=True)
This process takes a long time, about one night or day.
If you have already carried out the process before and there are the Tsys+Tant calibration tables (The directory name of the table includes “tsystant”), you can skip the generating of the tables using the following command.
#In CASA
sol_ampcal_2(mso, mso+'.tsys', exisTbl=True, outCSV=False)
Flagging after Tsys and Tsys+Tant calibration
Since we completed the Tsys and Tsys+Tant calibration, the data that are not used the image synthesis are flagged. At first, the data of auto-correlation and atmosphere calibration are flagged as follows:
#In CASA
flagdata(vis=mso, mode='manual', autocorr=True, flagbackup=False)
flagdata(vis=mso, mode='manual', intent='*ATMOSPHERE*', flagbackup=False)
Next is the spectrum windows that are not used in later:
#In CASA
flagdata(vis=mso, mode='manual', spw='0~4', flagbackup=False)
flagdata(vis=mso, mode='manual', spw='13~36', flagbackup=False)
The data in the channels near the both edges of the spectrum window (~10 channels) are flagged:
#In CASA
flagdata(vis=mso, mode='manual', flagbackup=False, spw='5:0~9;116~127,7:0~9;116~127,9:0~9;116~127,11:0~9;116~127')
The some sub-scans at the start and end of the scientific scans are used to measure the sky with the setting of optimized for the Sun. Since the data are used only for estimating the antenna temperatures at the Sun, we flag the data:
#In CASA
mymsmd = createCasaTool(msmdtool)
mymsmd.open(mso)
sciScan = mymsmd.scansforintent('*OBSERVE_TARGET*')
mymsmd.done()
for i in range(0, len(sciScan)):
subInf=aU.computeDurationOfScan(sciScan[i], vis=mso, returnSubscanTimes=True)
subNum = subInf[1]
flagdata(vis=mso, timerange=subInf[3][1], mode='manual', flagbackup=False)
flagdata(vis=mso, timerange=subInf[3][2],mode='manual', flagbackup=False)
flagdata(vis=mso, timerange=subInf[3][subNum-1], mode='manual', flagbackup=False)
flagdata(vis=mso, timerange=subInf[3][subNum], mode='manual', flagbackup=False)
As mentioned in the section #Tsys calibration of the calibrators, the Tsys values of DA54 antennas are significantly large. Therefore, we flag the data of the antenna as follows:
#In CASA
flagdata(vis=mso, antenna='DA54', mode='manual', flagbackup=False)
Then, we store the current flagging state for each dataset using the flagmanager:
#In CASA
flagmanager(vis=mso, mode='save', versionname='priori2')
Now split out the CORRECTED data column, retaining spectral windows 5,7,9, and 11. This will get rid of the extraneous spectral windows.
#In CASA
split(vis=mso, outputvis=mss, datacolumn='corrected', intent ='*BANDPASS*,*FLUX*,*PHASE*,*TARGET*', spw='5,7,9,11', keepflags=True)
Additional Data Inspection
We will do some additional inspection.
The solar data frequently include zero values in some channels. To avoid their influence, we flag the data using the “clip” mode with “clipzeros=True” option.
#In CASA
flagdata(vis=mss, mode='clip', clipzeros=True, flagbackup=False)
The valleys appear in the plot of amplitude vs channel of the Spw #3. It shows the effect of the lines of the earth atmosphere. We need to flag the data.
#In CASA
flagdata(vis=mss, spw='3:68~85', mode='manual', flagbackup=False)
flagdata(vis=mss, spw='3:20~40', mode='manual', flagbackup=False)
Then, we store the current flagging state for each dataset using the flagmanager:
#In CASA
flagmanager(vis=mss, mode='save', versionname='Initial')
Set up the Flux Calibration Model
It is very rare that a useful planet for the flux calibration is located near the Sun. Therefore, we usually use a quasar near the Sun as a flux calibrator. In this observations, there is no quasar that flux is enough for the observations with the Mixer De-tuning mode, except nrao350. Therefore, the flux calibrator is the same as the phase calibrator in this observation. To fill the model data column for nrao350 with a model for the flux density, we obtain the flux density and spectral index of the nro350 from the ALMA calibrator database.
#In CASA
intentSources=es.getIntentsAndSourceNames(mss)
ampCalId = intentSources['CALIBRATE_AMPLI']['id'] + intentSources['CALIBRATE_FLUX']['id']
calFieldNames = intentSources['CALIBRATE_AMPLI']['name'] + intentSources['CALIBRATE_FLUX']['name']
amp_cal_name=calFieldNames[1]
spwInfo=es.getSpwInfo(mss)
obs_freq="%fGHz"%(spwInfo[0]['refFreq']/1e9)
date=aU.getObservationStartDate(mss)
date_obs=date.split()[0]
spw1_flux=aU.getALMAFlux(sourcename=amp_cal_name, date=date_obs,frequency=obs_freq)
Then, fill the model data column for nrao350 with a model.
#In CASA
setjy(vis=mss, field='2', spw='0,1,2,3', standard='manual', fluxdensity=[spw1_flux['fluxDensity'], 0, 0, 0], spix= spw1_flux['spectralIndex'], reffreq=obs_freq)
Creating the Bandpass Calibration Table
The bandpass and gain calibrations are the same as the calibrations of non-solar data basically. Please refer to the other ALMA tutorials of the CASA guide too. The calibration method presented below is the same as that used in the QA2 process of the ALMA observatory.
At first, we determine the reference antenna, and run gaincal on the bandpass calibrator to determine phase-only gain solutions. We will use solint='int' for the solution interval, which means that one gain solution will be determined for every integration time.
#In CASA
ref_ant = 'DA41'
gaincal(vis=mss, caltable=mss+'.ap_pre_bandpass', field='1', scan='5', solint='int', refant=ref_ant, calmode='p')
The plots are created for the checking.
#In CASA
es.checkCalTable(mss+'.ap_pre_bandpass', msName=mss, interactive=False)
The plots look good. Next, create the bandpass calibration table:
#In CASA
bandpass(vis=mss, caltable=mss+'.bandpass', field='1', scan='5', solint='inf', refant=ref_ant, solnorm=True, bandtype='B', gaintable=mss+'.ap_pre_bandpass')
Check the bandpass calibration table using the plots created from the following command.
#In CASA
es.checkCalTable(mss+'.bandpass', msName=mss, interactive=False)
Creating the Gain Calibration Table
At first, we determine phase-only gain solutions of the calibrators, using the bandpass calibration table and solint='int' option, and create the plots for checking.
#In CASA
gaincal(vis=mss, caltable=mss+'.phase_int', field='1~2', solint='int', refant=ref_ant,gaintype='G',calmode='p',minsnr=3.0, gaintable=mss+'.bandpass')
es.checkCalTable(mss+'.phase_int', msName=mss, interactive=False)
Using the bandpass and phase calibration tables, we obtain the amplitude-only gain solutions on the scan time, solint='inf'.
# In CASA
gaincal(vis=mss, caltable=mss+'.ampli_inf', field='1~2', solint='inf', refant=ref_ant, gaintype='G', calmode='a', minsnr=3.0, gaintable=[mss+'.bandpass', mss+'.phase_int'])
es.checkCalTable(mss+'.ampli_inf', msName=mss, interactive=False)
Usually, the gaintype is set to 'T' for nominal ALMA observations . Nevetheless, the gaintype is set to 'G' for solar data, because the diffrence between XX and YY images is used for for estimating the noise level (see Section 4.2, Shimojo et al. 2017).
Next we use the flux calibrator (whose flux density was set in setjy above) to derive the flux density of the other calibrators. Note that the flux table REPLACES the amp.gcal in terms of future application of the calibration to the data, i.e. the flux table contains both the amp.gcal and flux scaling. Unlike the gain calibration steps, this is not an incremental table.
#In CASA
fluxscaleDict = fluxscale(vis=mss, caltable=mss+'.ampli_inf', fluxtable=mss+'.flux_inf', reference='2')
es.fluxscale2(caltable=mss+'.ampli_inf', removeOutliers=True, msName=mss, writeToFile=True, preavg=10000)
Finally, we create the gain calibration table of phase-only gain solutions on the scan time, solint='inf'.
#In CASA
gaincal(vis=mss, caltable=mss+'.phase_inf', field='1~2', solint='inf', refant=ref_ant, gaintype='G', calmode='p', minsnr=3.0, gaintable=mss+'.bandpass')
es.checkCalTable(mss+'.phase_inf', msName=mss, interactive=False)
Applying the Calibration Tables
We apply the calibration solutions to each source individually, using the gainfield parameter to specify which calibrator's solutions should be applied from each of the gaintable calibration tables. Applying the tables to the bandpass, flux and phase calibrators:
#In CASA
for i in ['1', '2']:
applycal(vis=mss, field=str(i), gaintable=[mss+'.bandpass', mss+'.phase_int', mss+'.flux_inf'], gainfield=['', i, i], interp='linear,linear', calwt=True, flagbackup=False)
Next, applying them to the solar data:
#In CASA
applycal(vis=mss, field='0, 3~150', gaintable=[mss+'.bandpass', mss+'.phase_inf', mss+'.flux_inf'], gainfield=['', '2', ''], interp='linear,linear', calwt=True, flagbackup=False)
Finally, split out the CORRECTED data column.
#In CASA
split(vis=mss, outputvis=msc, datacolumn='corrected', keepflags=True)
Re-calculation of the direction
During most solar observations, the antennas are tracking a structure on the Sun according to the solar differential rotation. The image frame is fixed on the solar frame, but the frame is moving on the RA/Dec coordinate frame. If we do not do any measures, the pattern of pointing in the MOSAIC observation is shown in Figure 3 , and the shape of the pattern is a rhombus though the correct shape is the square.
To correct the MOSAIC pattern, we re-calculate the coordinate of each field. At first, we modify the coordinate of the field “0” from the reference time using fixplanets task. The reference time has to be the time when the antennas are directed to the field “0”.
#In CASA
reftime = '2015/12/18/19:49:00'
fixplanets(msc, field='0', fixuvw=False, refant=ref_ant, reftime=reftime)
We define that the modified coordinate of field ’0’ is as the reference coordinate, and re-calculate the coordinate of each field, as follows.
#In CASA
tb.open(msc+'/FIELD', nomodify=True)
phsCenOff = tb.getcol("PHASE_DIR")
tb.close()
refRaDec = aU.rad2radec(phsCenOff[0][0][0], phsCenOff[1][0][0], prec=1, hmsdms=True, delimiter=' ')
for i in range(3, 151):
raOff = phsCenOff[0][0][i] * 180./pi * 60. *60.
deOff = phsCenOff[1][0][i] * 180./pi * 60. *60.
offRaDec = aU.radec2deg(aU.radecOffsetToRadec(refRaDec, raOff, deOff, prec=1))
offRaDecF = 'J2000 ' + aU.deg2radec(offRaDec[0], offRaDec[1], prec=1, hmsdms=True, delimiter=' ')
fixplanets(msc, field =str(i), fixuvw=False, direction=offRaDecF)
tb.open(msc+'/FIELD', nomodify=False)
tgt_refdir = tb.getcol("RefDir_Ref")
for id in range(3, len(tgt_refdir)):
tb.putcell("RefDir_Ref", id, 21)
tb.putcell("DelayDir_Ref", id, 21)
tb.putcell("PhaseDir_Ref", id, 21)
tb.close()
Moreover, the direction in the pointing table has a bad influence to the coordinate system of the image synthesis. We erase the pointing table as follows:
#In CASA
tb.open(msc+'/POINTING', nomodify = False)
a = tb.rownumbers()
tb.removerows(a)
As a result, the pattern of the pointing in the MOSAIC observation becomes the map, as shown in Figure 4.