MINT2
HyperBinningMakerMintRandomise.cpp
Go to the documentation of this file.
2 
3 
4 
6  HyperBinningMaker(binningRange, data)
7 {
8  WELCOME_LOG << "Good day from the HyperBinningMakerRandomise() Constructor"<<std::endl;
9 }
10 
12 
13  if (s_printBinning == true) INFO_LOG << "Splitting all bins in random dimensions"<<std::endl;
14  int dimension = _binningDimensions.size();
15 
16  int nBins = 0;
17  int unchanged = 0;
18 
19  while (splitAllRandomise() != 0){
20  if (nBins == getNumBins()) unchanged++;
21  else unchanged = 0;
22  if (unchanged >= 2.0*dimension) break;
23  nBins = getNumBins();
24  if (s_printBinning == true) INFO_LOG << "There is now a total of " << nBins << " bins"<<std::endl;
25  }
26 
27  if (s_printBinning == true) INFO_LOG << "Random binning algorithm complete "<<std::endl;
28 
29 
30 }
31 
33  GOODBYE_LOG << "Goodbye from the HyperBinningMakerRandomise() Constructor"<<std::endl;
34 }
#define INFO_LOG
static bool s_printBinning
HyperBinningMakerMintRandomise(const HyperCuboid &binningRange, const HyperPointSet &data)
#define GOODBYE_LOG
int splitAllRandomise(double splitPoint=0.5)
#define WELCOME_LOG
std::vector< int > _binningDimensions