Changeset 1454 in Sophya for trunk/ArchTOIPipe/TestPipes
- Timestamp:
- Apr 9, 2001, 2:14:21 PM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ArchTOIPipe/TestPipes/simtst.cc
r1443 r1454 20 20 } 21 21 else { 22 cout << "\n Usage : tstrztoi[-sproc] [-rwtoi] [-dbg] [-start snb] [-end sne] \n"22 cout << "\n Usage : simtst [-sproc] [-rwtoi] [-dbg] [-start snb] [-end sne] \n" 23 23 << " [-w1 sz] [-w2 sz] inFitsName outFitsName ppfFileName \n" 24 24 << " -sproc : Run RzSimpleTOIProc (default RzTOIProc) \n" … … 27 27 << " -start snb : sets the start sample num \n" 28 28 << " -end sne : sets the end sample num \n" 29 << " -range min,max : sets the acceptable range for intoi \n" 30 << " default= -16000,16000\n" 31 << " -intoi toiName : select input TOI name (def boloMuV_11)\n" 29 32 << " -w1 sz : sets main data window size (def= 8192)\n" 30 33 << " -w2 sz : sets secondary window size (def= 512) \n" … … 44 47 bool fgdbg = false; 45 48 int w1 = 8192; 46 int w2 = 512;49 int w2 = 256; 47 50 int nmax = 10; 48 51 int istart = 104121000+w1*5; 49 52 int iend = 0; 53 double range_min = -16000; 54 double range_max = 16000.; 50 55 string infile; 51 56 string outfile; 52 57 string ppffile; 58 string intoi = "boloMuV_11"; 53 59 54 60 if (narg < 4) Usage(true); … … 72 78 w2 = atoi(arg[ia+1]); ia++; 73 79 } 80 else if (strcmp(arg[ia],"-range") == 0) { 81 if (ia == narg-1) Usage(true); 82 sscanf(arg[ia+1],"%lf,%lf",&range_min, &range_max); 83 ia++; 84 } 85 else if (strcmp(arg[ia],"-intoi") == 0) { 86 if (ia == narg-1) Usage(true); 87 intoi = arg[ia+1]; ia++; 88 } 74 89 else if (strcmp(arg[ia],"-sproc") == 0) fgsimple = true; 75 90 else if (strcmp(arg[ia],"-rwtoi") == 0) fgrwtoi = true; … … 93 108 cout << ">>>> Window Size W1= " << w1 << " W2= " << w2 94 109 << " iStart= " << istart << " iEnd= " << iend << endl; 110 cout << ">>>> InTOIName= " << intoi << endl; 95 111 try { 96 112 TOIManager* mgr = TOIManager::getManager(); … … 109 125 110 126 111 char * colname[5] = {"MJD", "UTC","boloMuV_11","magnFlux","pivot"};112 char * toiname[5] = {"MJD", "UTC","bolo11","magneto","pivot"};127 // char * colname[5] = {"MJD", "UTC","boloMuV_11","magnFlux","pivot"}; 128 // char * toiname[5] = {"MJD", "UTC","bolo11","magneto","pivot"}; 113 129 TOISeqBuffered * toiin = new TOISeqBuffered("f2in", w1); 114 130 if (fgdbg) toiin->setDebugLevel(1); … … 129 145 // } 130 146 131 int kk = 2;132 r.addOutput( colname[kk], toiin);147 // int kk = 2; 148 r.addOutput(intoi, toiin); 133 149 // toi->dbg=true; 134 150 // r.addOutput("boloMuV_11", toi); … … 138 154 139 155 cout << " Creating SimpleDeglitcher() " << endl; 140 SimpleDeglitcher degl; 156 SimpleDeglitcher degl(w2); 157 cout << " Setting Range for deglitcher: " << range_min 158 << " - " << range_max << endl; 159 degl.SetRange(range_min, range_max); 141 160 degl.addInput("in", toiin); 142 161 degl.addOutput("out", toiout); … … 144 163 degl.addOutput("sigma", toisig); 145 164 degl.addOutput("incopie", toiincopie); 146 147 165 166 /* 167 cout << " Creating a GaussianFilter SimplFilterObject " << endl; 168 SimpleFilter filt(..) 169 TOISeqBuffered * toiincopie = new TOISeqBuffered("incopie", w1); 170 if (fgdbg) toiincopie->setDebugLevel(1); 171 */ 148 172 149 173 w.setOutFlags(true); … … 162 186 degl.start(); 163 187 w.start(); 164 165 // for(int jj=0; jj<3; jj++) { 166 // sleep(2); 167 // cout << *toi; 168 // } 188 189 /* 190 for(int jj=0; jj<3; jj++) { 191 cout << *toiin; 192 cout << *toiout; 193 sleep(1); 194 } 195 */ 169 196 170 197 mgr->joinAll();
Note:
See TracChangeset
for help on using the changeset viewer.