Commit db82b81c authored by Reza Ansari's avatar Reza Ansari
Browse files

Decodage option -inwsz pour classe VisiP4WindowReader Reza 15/12/2017

parent d8055d95
......@@ -177,7 +177,7 @@ std::vector<sa_size_t> P4AVisiNumEncoder::getAllVCrossCor()
//---------------------------------------------------------------------
P4AnaParams::P4AnaParams()
: inpath5_("bao5/"), inpath6_("bao6/"), Imin_(0), Imax_(10), Istep_(1),
fgserall_(false), fgtmsel_(false),
fgserall_(false), fgtmsel_(false), inwsz_(8),
fgreorderfreq_(false), gain_gnu_file_("gain.ppf"),
fitsoutfile_(""),outfile_("p4a.ppf"), Nmean_(10), prtlev_(0), prtmodulo_(1),
fgTFM_(false), TFMtimebin_(30), TFMfreqbin_(4), fgdtable_(false)
......@@ -187,7 +187,7 @@ P4AnaParams::P4AnaParams()
P4AnaParams::P4AnaParams(P4AnaParams const & a)
: inpath5_(a.inpath5_), inpath6_(a.inpath6_), Imin_(a.Imin_), Imax_(a.Imax_), Istep_(a.Istep_),
fgserall_(a.fgserall_), fgtmsel_(a. fgtmsel_),
fgserall_(a.fgserall_), fgtmsel_(a.fgtmsel_), inwsz_(a.inwsz_),
fgreorderfreq_(a.fgreorderfreq_), gain_gnu_file_(a.gain_gnu_file_),
outfile_(a.outfile_), Nmean_(a.Nmean_), prtlev_(a.prtlev_), prtmodulo_(a.prtmodulo_),
fgTFM_(a.fgTFM_), TFMtimebin_(a.TFMtimebin_), TFMfreqbin_(a.TFMfreqbin_),
......@@ -199,7 +199,7 @@ P4AnaParams& P4AnaParams::operator = (P4AnaParams const & a)
{
inpath5_=a.inpath5_; inpath6_=a.inpath6_;
Imin_=a.Imin_; Imax_=a.Imax_; Istep_=a.Istep_;
fgserall_=a.fgserall_; fgtmsel_=a. fgtmsel_;
fgserall_=a.fgserall_; fgtmsel_=a. fgtmsel_; inwsz_=a.inwsz_;
fgreorderfreq_=a.fgreorderfreq_; gain_gnu_file_=a.gain_gnu_file_;
outfile_=a.outfile_; Nmean_=a.Nmean_; prtlev_=a.prtlev_; prtmodulo_=a.prtmodulo_;
fgTFM_=a.fgTFM_; TFMfreqbin_=a.TFMfreqbin_; TFMtimebin_=a.TFMtimebin_;
......@@ -224,7 +224,10 @@ int P4AnaParams::DecodeArgs(int narg, const char* arg[])
tmsel_tu_=TimeStamp(arg[2]); tmsel_duration_=atof(arg[3]); fgserall_=false; fgtmsel_=true;
arg+=3; narg-=3; lastargs_.clear();
}
if (fbo=="-inwsz") { // specification taille de fenetre (en nb de matrices de visi) pour VisiP4WindowReader
if (narg<2) { cout << "P4AnaParams::DecodeArgs missing/bad argument, -h for help " << endl; return -1; }
inwsz_ = atol(arg[2]); arg+=2; narg-=2; lastargs_.clear();
}
else if (fbo=="-in5") {
if (narg<2) { cout << "P4AnaParams::DecodeArgs missing/bad argument, -h for help " << endl; return -1; }
inpath5_=arg[2]; arg+=2; narg-=2; lastargs_.clear();
......@@ -287,6 +290,7 @@ int P4AnaParams::UsageOptions()
<< " -inall : try to process all visibility matrices present in data directory \n"
<< " -inseltm date_timeTU duration : define set of visibility matrices to be processed as time interval \n"
<< " centered at date_timeTU (YYYY-MM-DDThh:mm:ss) and duration in minutes \n"
<< " -inwsz WindowSz : define the input visibility reader window size, as number of visi-matrices (VisiP4WindowReader) \n"
<< " -o outfilename : specify output file name \n"
<< " -fo outfilename : specify output fits name \n"
<< " -gnu gain_filename: gain g(nu) file name \n"
......@@ -316,6 +320,7 @@ ostream& P4AnaParams::Print(ostream& os) const
TimeStamp tuend = tmsel_tu_; tuend.ShiftSeconds(tmsel_duration_*30.);
os << " Process VisibMtx within time interval: TUStart=" << tustart.ToString() << " TUEnd="<<tuend.ToString()<<endl;
}
os<<" VisiP4WindowReader window size="<<inwsz_<<endl;
os<<" Gain, g(nu) file:"<<gain_gnu_file_<<" OutFile="<<outfile_<<endl;
os<<" Nmean="<<Nmean_<<" TFM: TimeBin="<<TFMtimebin_<<" FreqBin="<<TFMfreqbin_<<endl;
if (fbands_.size()==0) os<<" No frequency band defined ..."<<endl;
......
......@@ -148,7 +148,8 @@ public:
bool fgserall_; // if true, read all the visi matrices
TimeStamp tmsel_tu_; // selection defini par tmsel_tu_ +/- tmsel_duration_/2
double tmsel_duration_;
bool fgtmsel_; // if true, selection defined as tmsel_tu_ +/- tmsel_duration_/2
bool fgtmsel_; // if true, selection defined as tmsel_tu_ +/- tmsel_duration_/2
size_t inwsz_; // window size for VisiP4WindowReader
bool fgreorderfreq_;
//--- nom de fichier de gain
string gain_gnu_file_;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment