User Tools

Site Tools


huibintemaspampipeline

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
huibintemaspampipeline [2017/06/27 09:16] – [Combining multiple LTA files of one observation] huibintemahuibintemaspampipeline [2019/02/18 11:37] – [Old hardware-correlator observations] huibintema
Line 23: Line 23:
 Then we derive calibration and flagging information from the primary calibrator(s), pick the best one, transfer those informations to all other source visibilities present in the observation, and export each of these pre-calibrated visibility data sets to UVFITS: Then we derive calibration and flagging information from the primary calibrator(s), pick the best one, transfer those informations to all other source visibilities present in the observation, and export each of these pre-calibrated visibility data sets to UVFITS:
 <code python> <code python>
 +uvfits_file_name = "./fits/<project name>_<observe date>.lta.UVFITS"
 pre_calibrate_targets( uvfits_file_name, flags_file_name = lta_file_name + "##*.FLAGS*" ) pre_calibrate_targets( uvfits_file_name, flags_file_name = lta_file_name + "##*.FLAGS*" )
 </code> </code>
Line 40: Line 41:
 ./fits/<source name>.SP2B.PBCOR.FITS ./fits/<source name>.SP2B.PBCOR.FITS
  
-There'a million options available to make this process work for different / more complicated data sets. Some of the most common situations are discussed below.+The pipeline run can be summarized by typing: 
 +<code python> 
 +summarize_spam_log( "./datfil/spam_<source name>_<observation reference date>_<polarization(s)>_<sideband>*.log"
 +</code> 
 + 
 + 
 +There'many options available to make this process work for different / more complicated data sets. Some of the most common situations are discussed below. Note that more than one of these situations may reflect your data, and therefore multiple of the options discussed below may need to be combined.
  
 ----- -----
Line 116: Line 123:
 gv ./prtfil/*_BANDPASS.PS gv ./prtfil/*_BANDPASS.PS
 </code> </code>
-Select a channel range over which the bandpass phases are well-behaved (linear) for most antennas, then re-run+Select a channel range over which the bandpass phases are well-behaved (approximately linear) for most antennas, like in the following example plot. 
 +{{ :bandpass_example_1page.png?500 |}} 
 + 
 +Note down the lower- and upper-limit of the channel range. Then re-run //pre_calibrate_targets()// as follows:
 <code python> <code python>
-channel_range = [ 10225 ] # example channel range to keep+channel_range = [ 150425 ] # example channel range to keep
 pre_calibrate_targets( uvfits_file_name, channel_range = channel_range ) pre_calibrate_targets( uvfits_file_name, channel_range = channel_range )
 +</code>
 +
 +-----
 +
 +==== Old hardware-correlator observations ====
 +
 +If you downloaded data from cycle 17 or earlier, it is likely correlated using the GMRT Hardware Backend (GHB; a.k.a. the hardware correlator). For frequencies of 325 MHz and higher, the 32 MHz bandwidth is typically split over an upper-side band (USB) and lower-side band (LSB), both captured in separate LTA files (typical extensions are .lta and .ltb). In SPAM, both sideband LTA files need to be pre-processed separately:
 +<code python>
 +convert_lta_to_uvfits( lta_file_name )
 +convert_lta_to_uvfits( ltb_file_name )
 +</code>
 +The next step is run using the //keep_channel_one// option to enforce frequency continuity between the sidebands:
 +<code python>
 +pre_calibrate_targets( uvfits_file_name_lta, flags_file_name = lta_file_name + "##*.FLAGS*", keep_channel_one = True )
 +pre_calibrate_targets( uvfits_file_name_ltb, flags_file_name = ltb_file_name + "##*.FLAGS*", keep_channel_one = True )
 +</code>
 +The resulting UVFITS files for USB and LSB per target can be combined:
 +<code python>
 +uvfits_file_name_usb = "./fits/<target>_GMRT<frequency>_<date>_<stokes>_USB.UVFITS"
 +uvfits_file_name_lsb = "./fits/<target>_GMRT<frequency>_<date>_<stokes>_LSB.UVFITS"
 +uvfits_file_name = "./fits/<target>_GMRT<frequency>_<date>_<stokes>.UVFITS"
 +combine_usb_lsb( uvfits_file_name_usb, uvfits_file_name_lsb, uvfits_file_name )
 +</code>
 +The output UVFITS file can be processed further in the main pipeline.
 +
 +Regarding the main pipeline, there are two options that may be relevant to get to better results. The first option related to the situation explained above, where two sidebands (USB and LSB) are joined together to cover 32 MHz of bandwidth. In that case, it may help to turn on an image-based flagging option that treats the joined USB and LSB separately. Reason for this is that the USB and LSB have separate signal chains, and thus there can be system problems that relate only to one of the two sidebands.
 +<code python>
 +process_target( target_uvfits_file_name, flag_image_usb_lsb = True )
 +</code>
 +
 +The second option is to turn on baseline-based calibration, BUT ONLY AFTER VERY CAREFUL CONSIDERATION. In an ideal world, baseline-based calibration would never be necessary. However, I have witnessed situations using hardware-correlator data in which residual gain errors on baselines did not seem to be solely antenna-based. Baseline-based calibration is something to try as a last resort, and can be switched on in the pipeline as shown below. Please note that this is implemented under strict limitations: baseline-calibration is applied only in the final stages of the processing, and is determined on a per-observation base (meaning only one correction per baseline per observe session).
 +<code python>
 +process_target( target_uvfits_file_name, do_blcal = True )
 </code> </code>
  
Line 142: Line 185:
  
 ----- -----
 +
 +Feedback: [[huib.intema@curtin.edu.au|Click here]]
  
huibintemaspampipeline.txt · Last modified: 2020/10/05 17:46 by huibintema

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki