Changeset 3656 in Sophya for trunk/AddOn/TAcq/brproc.cc
- Timestamp:
- Sep 9, 2009, 1:56:34 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/AddOn/TAcq/brproc.cc
r3655 r3656 36 36 /* --Methode-- */ 37 37 BRProcARaw2C::BRProcARaw2C(RAcqMemZoneMgr& mem, string& path, uint_4 nmean, 38 uint_4 nmax, bool fghist, bool fgnotrl, int card)38 uint_4 nmax, bool fghist, uint_4 nfsmap, bool fgnotrl, int card) 39 39 : memgr(mem) 40 40 { 41 41 nmax_ = nmax; 42 42 nmean_ = nmean; 43 nfsmap_ = nfsmap; 43 44 stop_ = false; 44 45 path_ = path; … … 113 114 */ 114 115 116 bool fgtimfreq = false; // true->cartes temps<>frequences 117 if (nfsmap_>0) fgtimfreq=true; 118 115 119 TVector< complex<r_4> > cfour2(cfour1.Size()); 116 120 … … 123 127 TVector< complex<r_4> > visiV12( cfour1.Size() ); 124 128 129 TMatrix<r_4> timfreqV1, timfreqV2; // Cartes temps<>frequences 130 if (fgtimfreq) { 131 timfreqV1.SetSize(nmean_, spectreV1.Size()/nfsmap_); 132 timfreqV2.SetSize(nmean_, spectreV2.Size()/nfsmap_); 133 } 125 134 cout << " *DBG*BRProcARaw2C PaqSz=" << paqsz << " ProcPaqSize=" << procpaqsz 126 135 << " procpaqsz/2=" << procpaqsz/2 << " cfour1.Size()=" << cfour1.Size() … … 181 190 spectreV1(j) += Zmod2(cfour1(j)); 182 191 memcpy(procbuff+i*procpaqsz, cfour1.Data(), sizeof(complex<r_4>)*cfour1.Size()); 192 if (fgtimfreq) { // Remplissage tableau temps-frequence 193 for(sa_size_t c=1; c<timfreqV1.NCols(); c++) { 194 for(sa_size_t j=c*nfsmap_; j<(c+1)*nfsmap_; j++) 195 timfreqV1(nzm, c) += Zmod2(cfour1(j)); 196 } 197 } 183 198 // Traitement voie 2 184 199 if (fghist_) { … … 197 212 spectreV2(j) += Zmod2(cfour2(j)); // Zmod2(zp2[j]); 198 213 memcpy(procbuff+i*procpaqsz+procpaqsz/2, cfour2.Data(), sizeof(complex<r_4>)*cfour2.Size()); 214 if (fgtimfreq) { // Remplissage tableau temps-frequence 215 for(sa_size_t c=1; c<timfreqV2.NCols(); c++) { 216 for(sa_size_t j=c*nfsmap_; j<(c+1)*nfsmap_; j++) 217 timfreqV2(nzm,c) += Zmod2(cfour2(j)); 218 } 219 } 199 220 200 221 // Calcul correlation (visibilite V1 * V2) … … 268 289 string tagh1="tshV1"; 269 290 string tagh2="tshV2"; 291 string tagtf1="timfreqV1"; 292 string tagtf2="timfreqV2"; 270 293 if (card_==2) { 271 294 tag1 = "specV3"; … … 274 297 tagh2 = "tshV2"; 275 298 tag12="visiV34"; 299 tagtf1="timfreqV3"; 300 tagtf2="timfreqV4"; 276 301 } 277 302 po << PPFNameTag(tag1) << spectreV1; … … 281 306 po << PPFNameTag(tagh1) << h1; 282 307 po << PPFNameTag(tagh2) << h2; 308 } 309 if (fgtimfreq) { 310 timfreqV1 /= (r_4)nzm; 311 timfreqV2 /= (r_4)nzm; 312 po << PPFNameTag(tagtf1) << timfreqV1; 313 po << PPFNameTag(tagtf2) << timfreqV2; 283 314 } 284 315 } … … 290 321 h2.Zero(); 291 322 } 323 if (fgtimfreq) { 324 timfreqV1 = (r_4)(0.); 325 timfreqV2 = (r_4)(0.); 326 } 292 327 nzm = 0; ifile++; 293 328 // ts.SetNow();
Note:
See TracChangeset
for help on using the changeset viewer.