diff --git a/slsDetectorCalibration/moenchExecutables/CMakeLists.txt b/slsDetectorCalibration/moenchExecutables/CMakeLists.txt index c293acea4..2faa1d852 100644 --- a/slsDetectorCalibration/moenchExecutables/CMakeLists.txt +++ b/slsDetectorCalibration/moenchExecutables/CMakeLists.txt @@ -35,7 +35,7 @@ target_compile_definitions(moench04RawDataProcess PRIVATE MOENCH04) list(APPEND MOENCH_EXECUTABLES moench04RawDataProcess) add_executable(moench04RawDataProcessDGS moenchRawDataProcess.cpp) -target_compile_definitions(moench04RawDataProcess PRIVATE MOENCH04_DGS MOENCH04) +target_compile_definitions(moench04RawDataProcessDGS PRIVATE MOENCH04_DGS MOENCH04) list(APPEND MOENCH_EXECUTABLES moench04RawDataProcessDGS) #interpolation stuff diff --git a/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp b/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp index 0845bfbbc..cfcddf347 100644 --- a/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp +++ b/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp @@ -74,7 +74,7 @@ int main(int argc, char *argv[]) { #ifdef MOENCH04 #ifndef MOENCH04_DGS - moench04CtbZmq10GbData *decoder = new moench04CtbZmq10GbData(); + moench04CtbZmq10GbData *decoder = new moench04CtbZmq10GbData(5000,0); cout << "MOENCH04!" << endl; #endif @@ -349,7 +349,7 @@ int main(int argc, char *argv[]) { mt->popFree(buff); ifr++; - if (ifr % 100 == 0) + if (ifr % 100 == 0) cout << ifr << " " << ff << endl; if (nframes > 0) { if (ifr % nframes == 0) { @@ -361,8 +361,10 @@ int main(int argc, char *argv[]) { ifile++; } } - } else - cout << ifr << " " << ff << " " << np << endl; + } else { + cout << "bp " << ifr << " " << ff << " " << np << endl; + //break; + } ff = -1; } cout << "--" << endl; diff --git a/slsDetectorCalibration/singlePhotonDetector.h b/slsDetectorCalibration/singlePhotonDetector.h index eb0e3ce6b..d647cde16 100644 --- a/slsDetectorCalibration/singlePhotonDetector.h +++ b/slsDetectorCalibration/singlePhotonDetector.h @@ -429,29 +429,30 @@ class singlePhotonDetector : public analogDetector { for (ic = -(clusterSize / 2); ic < (clusterSize / 2) + 1; ic++) { - if ((iy + ir) >= 0 && (iy + ir) < ny && + if ( (iy + ir) >= 0 && (iy + ir) < ny && (ix + ic) >= 0 && (ix + ic) < nx) { - if ((iy + ir) >= iy && (ix + ic) >= ix ) { - val[(iy + ir) * nx + ix + ic] = + if ((iy + ir) > iy && (ix + ic) > ix ) { + + val[(iy + ir) * nx + ix + ic] = subtractPedestal(data, ix + ic, iy + ir, cm); - - } - v = &(val[(iy + ir) * nx + ix + ic]); - tot += *v; - if (ir <= 0 && ic <= 0) - bl += *v; - if (ir <= 0 && ic >= 0) - br += *v; - if (ir >= 0 && ic <= 0) - tl += *v; - if (ir >= 0 && ic >= 0) + + } + v = &(val[(iy + ir) * nx + ix + ic]); + tot += *v; + if (ir <= 0 && ic <= 0) + bl += *v; + if (ir <= 0 && ic >= 0) + br += *v; + if (ir >= 0 && ic <= 0) + tl += *v; + if (ir >= 0 && ic >= 0) tr += *v; - if (*v > max) //{ - max = *v; - //} + if (*v > max) //{ + max = *v; + //} } } }