Skip to content

Commit 2dd1e93

Browse files
committed
detect and ban drift
1 parent c8082ad commit 2dd1e93

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

Source/MultiDetector.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,6 @@ void MultiDetector::process(AudioSampleBuffer& buffer)
185185
// Use globalSample so it is not relative to the buffer
186186
globalSample = 0;
187187

188-
189188
if (isCalibration == true) {
190189

191190
elapsedCalibration++;
@@ -228,7 +227,6 @@ void MultiDetector::process(AudioSampleBuffer& buffer)
228227
//std::cout << "Sample: " << sample << " Downsample: " << sample/downsampleFactor << " Time: " << (unsigned int)(1000.f * float(tsBuffer + sample) / samplingRate) << std::endl;
229228
//std::cout << "Write: " << roundBufferWriteIndex << " Read: " << roundBufferReadIndex << std::endl;
230229

231-
232230
unsigned int temporalReadIndex = roundBufferReadIndex;
233231
unsigned int oldRoundBufferReadIndex = roundBufferReadIndex;
234232
// Next value to read will be the first upcoming window after stride, if no event is found

Source/MultiDetector.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ namespace MultiDetectorSpace
133133
unsigned int roundBufferNumElements;
134134

135135
std::vector<float> predictBuffer;
136-
float predictBufferSum[NUM_CHANNELS];
136+
std::vector<float> predictBufferSum;
137137
unsigned int predictBufferSize;
138138
int effectiveStride;
139139
float thrDrift;

0 commit comments

Comments
 (0)