MWATelescope / cotter

André Offringa's cotter pre-processing pipeline
9 stars 3 forks source link

full-apply option fails on picket fence observations #8

Closed gsleap closed 4 years ago

gsleap commented 4 years ago

Steps to reproduce:

I think the -fully-apply option is comparing the number of fine channels in the first contiguous subband (in the example below it's 1/2 the channels == 1536) with the number of channels in the calibration solution (the calibration solution .bin file will always just have all channels- in this case 3072).

So in a two subband picket fence like the one in the example, -full-apply needs to apply the calibration solutions from the .bin file for channels 0-1535 to the first contiguous band and then apply the calibration solutions from the .bin file for channels 1536-3071 to the second contiguous band.

Example:

$ cotter -absmem 64 -timeres 0.5 -freqres 10 -edgewidth 80 -initflag 4 -allowmissing -flagfiles 1245504832_%%.mwaf -full-apply cal/1245514896.bin -m 1245504832.metafits -o 1245504832.ms *.fits

Running Cotter MWA preprocessing pipeline, version 4.2 (2018-07-05).
Flagging is performed by AOFlagger 2.9.0 (2016-12-20).
Input filenames succesfully parsed: using 120 files covering 5 timeranges from 24 GPU boxes.
Using 64/125.6 GB of system memory.
Ignored keyword: ATTEN_DB
Ignored keyword: CHANSEL
Ignored keyword: INSTRUME
Ignored keyword: QUACKTIM
Ignored keyword: GOODTIME
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: COMMENT
Ignored keyword: HISTORY
Ignored keyword: HISTORY
Ignored keyword: HISTORY
Observation covers 72.32-169.59 MHz.
Output resolution: 0.5 s / 10 kHz (time avg: 1x, freq avg: 1x).
The first 8 samples (4 s), last 0 samples (0 s) and 8 edge channels will be flagged.
Using a-priori subband passband with 128 channels.
Using per-input subband gains. Average gains: 2.23853,2.00562,1.77026,1.57214,1.44202,1.38708,1.39087,1.40527,1.41077,1.38721,1.34753,1.30823,1.03528,1.0332,1.02271,1.01282,1.00232,0.997559,1,1.01001,1.01428,1.02368,1.03784,1.04456
Subband order: 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,23,22,21,20
Observation's bandwidth is non-contiguous.
 |=== BAND 1 / 2 ===|
Writing contiguous band 1 to 1245504832057-068.ms.

An unhandled exception occured while running Cotter:
The provided solution file has an incorrect number of channels. Oobservation has 1536 channels, and solution file has 3072 channels.
skitaeff commented 4 years ago

Hi @aroffringa, any chance to look into this any time soon?