Commits
177 177 | FringeJonesTest() : |
178 178 | VisCalTestBase(1, // nfield |
179 179 | 1, // nscan |
180 180 | 1, // nspw |
181 181 | 7, // nant |
182 182 | 4, // ncorr |
183 183 | 64, // nchan per spw |
184 184 | 16, // ntime per scan |
185 185 | false), // unpolarized |
186 186 | // nPar, 1, {1 | nAntennas} |
187 - | fpar(6, 1, VisCalTestBase::nAnt, 0.0f) // 6 pars per antenna |
187 + | fpar(8, 1, VisCalTestBase::nAnt, 0.0f) // 8 pars per antenna |
188 188 | { |
189 189 | // Add FringeJonesTest specific init |
190 190 | // e.g., fill fpar with interesting values |
191 191 | for (Int i=1; i!=VisCalTestBase::nAnt; i++) { |
192 192 | // 1, 4 are delay. |
193 193 | fpar(1, 0, i) = 2.3; |
194 - | fpar(4, 0, i) = -1.7; |
195 - | // Parameters 2 and 5 are rate. But VisCal::setMeta currently |
194 + | fpar(5, 0, i) = -1.7; |
195 + | // Parameters 2 and 6 are rate. But VisCal::setMeta currently |
196 196 | // only supports a single double for time, and this meta data is |
197 197 | // used to generate all the Jones matrices for the FringeJones |
198 198 | // (or any other VisCal subclass) calibrater; I don't feel |
199 199 | // comfortable enough with the calibration stack to try to |
200 200 | // intervene on this, so for now we can only test zero rates for |
201 201 | // the FringeJones class proper. |
202 202 | fpar(2, 0, i) = 0.0; |
203 - | fpar(5, 0, i) = 0.0; |
203 + | fpar(6, 0, i) = 0.0; |
204 204 | } |
205 205 | // uncomment to see data shape summary from |
206 206 | //VisCalTestBase::summary("FringeJonesTest"); |
207 207 | } |
208 208 | }; |
209 209 | |
210 210 | |
211 211 | TEST_F(FringeJonesTest, FringeJonesApplyState) { |
212 212 | |
213 213 | FringeJones ff(VisCalTestBase::msmc); |
329 329 | Float rate2 = 0.0; |
330 330 | |
331 331 | if (FRINGEJONES_TEST_VERBOSE) { |
332 332 | cerr << "delay1 results " << p(1,1) << endl; |
333 333 | cerr << "delay2 results " << p(4,1) << endl; |
334 334 | cerr << "rate1 results " << p(2,1) << endl; |
335 335 | cerr << "rate2 results " << p(5,1) << endl; |
336 336 | cerr << "Parameters out: " << p << endl; |
337 337 | } |
338 338 | ASSERT_TRUE(allNearAbs(p(1, 1), delay1, 2e-2)); |
339 - | ASSERT_TRUE(allNearAbs(p(4, 1), delay2, 2e-2)); |
339 + | ASSERT_TRUE(allNearAbs(p(5, 1), delay2, 2e-2)); |
340 340 | |
341 341 | ASSERT_TRUE(allNearAbs(p(2, 1), rate1, 1e-5)); |
342 - | ASSERT_TRUE(allNearAbs(p(5, 1), rate2, 1e-5)); |
342 + | ASSERT_TRUE(allNearAbs(p(6, 1), rate2, 1e-5)); |
343 343 | |
344 344 | ASSERT_TRUE(FJsol.refant()==0); |
345 345 | |
346 346 | } |