Skip to content

Commit

Permalink
ReaderLib/BlockRandomizer.cpp: report on StartEpoch if verbosity >= 1
Browse files Browse the repository at this point in the history
  • Loading branch information
mahilleb-msft committed Aug 31, 2016
1 parent 42d85eb commit adae0db
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions Source/Readers/ReaderLib/BlockRandomizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,16 +78,17 @@ void BlockRandomizer::StartEpoch(const EpochConfiguration& config)
size_t newOffset = m_sequenceRandomizer->Seek(offsetInSweep, m_sweep);
m_globalSamplePosition = m_sweep * m_sweepTotalNumberOfSamples + newOffset;

#ifdef _DEBUG
size_t epochStartFrame = config.m_epochIndex * m_epochSize;
fprintf(stderr, "BlockRandomizer::StartEpoch: epoch %" PRIu64 ": samples [%" PRIu64 "..%" PRIu64 "] (first sequence at sample %" PRIu64 "), worker rank %" PRIu64 ", total workers %" PRIu64 "\n",
config.m_epochIndex + 1,
epochStartFrame,
epochStartFrame + m_epochSize,
m_globalSamplePosition,
config.m_workerRank,
config.m_numberOfWorkers);
#endif
if (m_verbosity >= Notification)
{
size_t epochStartFrame = config.m_epochIndex * m_epochSize;
fprintf(stderr, "BlockRandomizer::StartEpoch: epoch %" PRIu64 ": samples [%" PRIu64 "..%" PRIu64 "] (first sequence at sample %" PRIu64 "), worker rank %" PRIu64 ", total workers %" PRIu64 "\n",
config.m_epochIndex + 1,
epochStartFrame,
epochStartFrame + m_epochSize,
m_globalSamplePosition,
config.m_workerRank,
config.m_numberOfWorkers);
}
}

// Prepares a new sweep if needed.
Expand Down

0 comments on commit adae0db

Please sign in to comment.