mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-24 23:30:03 +02:00
some bugs in the analysis solved
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@710 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
parent
356801a3dd
commit
9517d4f0f2
@ -12,7 +12,7 @@ postProcessingFuncs::postProcessingFuncs(int *nModules,int *chPerMod,int modMask
|
||||
|
||||
int postProcessingFuncs::initDataset() {
|
||||
|
||||
// cout << "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA init dataset " << endl;
|
||||
cout << "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA init dataset " << endl;
|
||||
|
||||
if (nBins) {
|
||||
mp=new double[nBins];
|
||||
@ -34,7 +34,7 @@ int postProcessingFuncs::initDataset() {
|
||||
|
||||
int postProcessingFuncs::finalizeDataset(double *ang, double *val, double *err, int *np) {
|
||||
|
||||
// cout << "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA finalize dataset " << endl;
|
||||
cout << "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA finalize dataset " << endl;
|
||||
|
||||
if (nBins)
|
||||
*np=finalizeMerging(mp,mv,me,mm,nBins);
|
||||
@ -62,15 +62,27 @@ int postProcessingFuncs::finalizeDataset(double *ang, double *val, double *err,
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (mp)
|
||||
// cout << "delete mp " <<endl;
|
||||
if (mp) {
|
||||
delete [] mp;
|
||||
if (mv)
|
||||
mp=NULL;
|
||||
}
|
||||
// cout << "delete mv " <<endl;
|
||||
if (mv) {
|
||||
delete [] mv;
|
||||
if (me)
|
||||
mv=NULL;
|
||||
}
|
||||
// cout << "delete me " <<endl;
|
||||
if (me) {
|
||||
delete [] me;
|
||||
if (mm)
|
||||
me=NULL;
|
||||
}
|
||||
// cout << "delete mm " <<endl;
|
||||
if (mm) {
|
||||
delete [] mm;
|
||||
mm=NULL;
|
||||
|
||||
}
|
||||
|
||||
|
||||
return 0;
|
||||
@ -536,6 +548,7 @@ int postProcessingFuncs::calculateFlatField(int* nModules, int *chPerMod, int *m
|
||||
cout << "done " << endl;
|
||||
|
||||
delete [] xmed;
|
||||
xmed=NULL;
|
||||
|
||||
return 0;
|
||||
|
||||
|
@ -421,7 +421,7 @@ void singlePhotonFilter::findHits(){
|
||||
int clusterIndex;
|
||||
// single_photon_hit *hit;
|
||||
|
||||
double clusterData[nClusterX*nClusterY];// = hit.data;
|
||||
double *clusterData;//[nClusterX*nClusterY];// = hit.data;
|
||||
double sigmarms;
|
||||
double clusterrms;
|
||||
double clusterped;
|
||||
|
@ -25,8 +25,8 @@ class single_photon_hit {
|
||||
~single_photon_hit(){delete [] data;};
|
||||
void write(FILE *myFile) {fwrite((void*)this, 1, 3*sizeof(int)+2*sizeof(double), myFile); fwrite((void*)data, 1, dx*dy*sizeof(double), myFile);};
|
||||
void read(FILE *myFile) {fread((void*)this, 1, 3*sizeof(int)+2*sizeof(double), myFile); fread((void*)data, 1, dx*dy*sizeof(double), myFile);};
|
||||
void set_data(double v, int ix, int iy=0){data[(iy+ny/2)*nx+ix+nx/2]=v;};
|
||||
double get_data(int ix, int iy=0){return data[(iy+ny/2)*nx+ix+nx/2];};
|
||||
void set_data(double v, int ix, int iy=0){data[(iy+dy/2)*dx+ix+dx/2]=v;};
|
||||
double get_data(int ix, int iy=0){return data[(iy+dy/2)*dx+ix+dx/2];};
|
||||
|
||||
|
||||
int x; /**< x-coordinate of the center of hit */
|
||||
|
Loading…
x
Reference in New Issue
Block a user