Source
473
473
return vii;
474
474
}
475
475
476
476
477
477
/********************************/
478
478
479
479
480
480
// -----------------------------------------------------------------------
481
481
CalSolvingVi2::CalSolvingVi2( vi::ViImplementation2 * inputVii,
482
482
const CalibratingParameters& calpar) :
483
-
CalibratingVi2 (inputVii,calpar)
484
-
483
+
CalibratingVi2 (inputVii,calpar),
484
+
corrDepFlags_(false)
485
485
{
486
486
corrFactor_p=sqrt(corrFactor_p);
487
487
}
488
488
489
489
// -----------------------------------------------------------------------
490
490
CalSolvingVi2::CalSolvingVi2( vi::ViImplementation2 * inputVii,
491
491
const CalibratingParameters& calpar,
492
492
String msname) :
493
-
CalibratingVi2 (inputVii,calpar,msname)
493
+
CalibratingVi2 (inputVii,calpar,msname),
494
+
corrDepFlags_(false)
494
495
{
495
496
// Nothing specialized to do here (except ctor parent, above)
496
497
}
497
498
498
499
// -----------------------------------------------------------------------
499
500
CalSolvingVi2::CalSolvingVi2( vi::ViImplementation2 * inputVii,
500
-
VisEquation *ve) :
501
-
CalibratingVi2 (inputVii,ve)
501
+
VisEquation *ve,
502
+
const Bool& corrDepFlags) :
503
+
CalibratingVi2 (inputVii,ve),
504
+
corrDepFlags_(corrDepFlags)
502
505
{
503
506
// Nothing specialized to do here (except ctor parent, above)
504
507
}
505
508
506
509
//#define REPORTTIMING
507
510
508
511
// -----------------------------------------------------------------------
509
512
//
510
513
// -----------------------------------------------------------------------
511
514
CalSolvingVi2::~CalSolvingVi2()
721
724
#endif
722
725
723
726
// Ensure we got weightSpectrum (fill it, if not)
724
727
verifyWeightSpectrum(vb);
725
728
726
729
#ifdef _OPENMP
727
730
Double time1b=omp_get_wtime();
728
731
#endif
729
732
730
733
// Set old-style flags, FOR NOW
731
-
corrIndepFlags(vb);
732
-
734
+
if (!corrDepFlags_)
735
+
corrIndepFlags(vb);
736
+
733
737
#ifdef _OPENMP
734
738
Double time2=omp_get_wtime();
735
739
#endif
736
740
737
741
// If the VisEquation is set, use it, otherwise use the corrFactor_p
738
742
if (ve_p) {
739
743
740
744
// Apply calibration via the VisEquation
741
745
ve_p->collapse2(*vb); // ,False,doWtSp);
742
746
890
894
891
895
// CalSolvingVi2-specific layer-creater
892
896
ViImplementation2 * CalSolvingVi2LayerFactory::createInstance (ViImplementation2* vii0) const {
893
897
// Make the CalibratingVi2, using supplied ViImplementation2, and return it
894
898
ViImplementation2 *vii = new CalSolvingVi2(vii0,calpars_);
895
899
return vii;
896
900
}
897
901
898
902
899
903
900
-
CalSolvingVi2LayerFactoryByVE::CalSolvingVi2LayerFactoryByVE(VisEquation *ve)
904
+
CalSolvingVi2LayerFactoryByVE::CalSolvingVi2LayerFactoryByVE(VisEquation *ve,const casacore::Bool& corrDepFlags)
901
905
: ViiLayerFactory(),
902
-
ve_p(ve)
906
+
ve_p(ve),
907
+
corrDepFlags_(corrDepFlags)
903
908
{
904
-
905
909
// ve_p->state();
906
910
907
911
}
908
912
909
913
// CalSolvingVi2-specific layer-creater
910
914
ViImplementation2 * CalSolvingVi2LayerFactoryByVE::createInstance (ViImplementation2* vii0) const {
911
915
// Make the CalibratingVi2, using supplied ViImplementation2, and return it
912
-
ViImplementation2 *vii = new CalSolvingVi2(vii0,ve_p);
916
+
ViImplementation2 *vii = new CalSolvingVi2(vii0,ve_p,corrDepFlags_);
913
917
return vii;
914
918
}
915
919
916
920
917
921
918
922
919
923
920
924
921
925
922
926