src/training/common/sampleiterator.cpp
int SampleIterator::UniformSamples() {
  int num_good_samples = 0;
  for (Begin(); !AtEnd(); Next()) {
    TrainingSample *sample = MutableSample();
    sample->set_weight(1.0);
    ++num_good_samples;
  }
  NormalizeSamples();
  return num_good_samples;
}
// Adjust the weights of all the samples to be uniform in the given charset.
// Returns the number of samples in the iterator.
Adjust the weights of all the samples to be uniform in the given charset.
Returns the number of samples in the iterator.
Adjust the weights of all the samples to be uniform in the given charset . Returns the number of samples in the iterator .
int SampleIterator::UniformSamples() {
  int num_good_samples = 0;
  for (Begin(); !AtEnd(); Next()) {
    TrainingSample *sample = MutableSample();
    sample->set_weight(1.0);
    ++num_good_samples;
  }
  NormalizeSamples();
  return num_good_samples;
}
int SampleIterator :: UniformSamples ( ) { int num_good_samples = 0 ; for ( Begin ( ) ; ! AtEnd ( ) ; Next ( ) ) { TrainingSample * sample = MutableSample ( ) ; sample -> set_weight ( 1.0 ) ; ++ num_good_samples ; } NormalizeSamples ( ) ; return num_good_samples ; }
Adjust the weights of all the samples to be uniform in the given charset.
Adjust the weights of all the samples to be uniform in the given charset .