mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-26 08:10:02 +02:00
filter runs from 1..159
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorCalibration@27 113b152e-814d-439b-b186-022a431db7b5
This commit is contained in:
parent
849c5eb190
commit
50acdf5628
@ -53,7 +53,7 @@ Loops over data file to find single photons, fills the tree (and writes it to fi
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
THStack *moenchReadData(char *fformat, char *tit, int runmin, int runmax, int nbins=1500, int hmin=-500, int hmax=1000, int sign=1, double hc=0, int xmin=0, int xmax=NC, int ymin=0, int ymax=NR, int cmsub=0, int hitfinder=1) {
|
THStack *moenchReadData(char *fformat, char *tit, int runmin, int runmax, int nbins=1500, int hmin=-500, int hmax=1000, int sign=1, double hc=0, int xmin=1, int xmax=NC-1, int ymin=1, int ymax=NR-1, int cmsub=0, int hitfinder=1) {
|
||||||
|
|
||||||
moench02ModuleData *decoder=new moench02ModuleData(hc);
|
moench02ModuleData *decoder=new moench02ModuleData(hc);
|
||||||
moenchCommonMode *cmSub=NULL;
|
moenchCommonMode *cmSub=NULL;
|
||||||
|
@ -12,10 +12,13 @@ typedef struct task_s{
|
|||||||
} Task;
|
} Task;
|
||||||
|
|
||||||
void *moenchMakeTreeTask(void *p){
|
void *moenchMakeTreeTask(void *p){
|
||||||
|
TThread::Lock();
|
||||||
char fname[1000];
|
char fname[1000];
|
||||||
Task *t = (Task *)p;
|
Task *t = (Task *)p;
|
||||||
sprintf(fname,"%s%s_%i.root",t->tdir,t->tname,t->treeIndex);
|
sprintf(fname,"%s%s_%i.root",t->tdir,t->tname,t->treeIndex);
|
||||||
TFile *f = new TFile(fname,"RECREATE");
|
TFile *f = new TFile(fname,"RECREATE");
|
||||||
|
cout << "Call moenchReadData(" << t->fformat << "," << t->tname << "," << t->runmin<< "," << t->runmax <<")" << endl;
|
||||||
|
TThread::UnLock();
|
||||||
moenchReadData(t->fformat,t->tname,t->runmin,t->runmax);
|
moenchReadData(t->fformat,t->tname,t->runmin,t->runmax);
|
||||||
f->Close();
|
f->Close();
|
||||||
return 0;
|
return 0;
|
||||||
@ -38,6 +41,11 @@ void moenchReadDataMT(char *fformat, char *tit, char *tdir, int runmin, int runo
|
|||||||
threads[i] = new TThread(threadName, moenchMakeTreeTask, t);
|
threads[i] = new TThread(threadName, moenchMakeTreeTask, t);
|
||||||
threads[i]->Run();
|
threads[i]->Run();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for(int i = 0; i < nThreads; i++){
|
||||||
|
threads[i]->Join();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user