Commit 8fb866d8 authored by niklas.baumgarten's avatar niklas.baumgarten
Browse files

adding bool to be able to switch off sample distribution

parent 2200bca1
......@@ -9,16 +9,22 @@ struct SampleCounter {
int dM = 0;
int dMComm = 0;
int commSplit = 0;
int distSamples = false;
SampleCounter() {};
SampleCounter(int dM) : dM(dM) {
for (int i = 0; i < ceil(log2(PPM->Size(0))) + 1; i++) {
if (dM >= PPM->Size(i)) {
dMComm = ceil((double) dM / PPM->Size(i));
commSplit = PPM->MaxCommSplit() - i;
break;
if (distSamples) {
for (int i = 0; i < ceil(log2(PPM->Size(0))) + 1; i++) {
if (dM >= PPM->Size(i)) {
dMComm = ceil((double) dM / PPM->Size(i));
commSplit = PPM->MaxCommSplit() - i;
break;
}
}
} else {
dMComm = dM;
commSplit = 0;
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment