Skip to content
Snippets Groups Projects
Commit d97562a1 authored by Martin Gels's avatar Martin Gels
Browse files

BugID: 1005

In function getObservationEpoch() the variable sz must be equal to noRuns.
These variables must be a multiple of 16, plus 16.
parent ddbb9228
No related branches found
No related tags found
No related merge requests found
...@@ -42,7 +42,6 @@ namespace LOFAR ...@@ -42,7 +42,6 @@ namespace LOFAR
namespace CS1 namespace CS1
{ {
INIT_TRACER_CONTEXT(WH_DelayCompensation, LOFARLOGGER_PACKAGE); INIT_TRACER_CONTEXT(WH_DelayCompensation, LOFARLOGGER_PACKAGE);
//##---------------- Public methods ----------------##// //##---------------- Public methods ----------------##//
...@@ -109,7 +108,6 @@ namespace LOFAR ...@@ -109,7 +108,6 @@ namespace LOFAR
void WH_DelayCompensation::process() void WH_DelayCompensation::process()
{ {
// Calculate the delays for the epoch after the end of the current time // Calculate the delays for the epoch after the end of the current time
// interval. Put the results in itsDelaysAtBegin and itsDelaysAfterEnd. // interval. Put the results in itsDelaysAtBegin and itsDelaysAfterEnd.
calculateDelays(); calculateDelays();
...@@ -286,6 +284,11 @@ namespace LOFAR ...@@ -286,6 +284,11 @@ namespace LOFAR
// Reserve space in \a itsObservationEpoch to avoid reallocations // Reserve space in \a itsObservationEpoch to avoid reallocations
uint sz = uint(1 + ceil((stopTime - startTime).mjd() / stepTime.mjd())); uint sz = uint(1 + ceil((stopTime - startTime).mjd() / stepTime.mjd()));
// Variable sz must be equal to noRuns. sz and noRuns must be a multiple
// of 16, plus 16.
sz = ((sz+15)&~15) + 16;
LOG_TRACE_VAR_STR(sz << " epoch(s)"); LOG_TRACE_VAR_STR(sz << " epoch(s)");
itsObservationEpoch.reserve(sz); itsObservationEpoch.reserve(sz);
...@@ -372,10 +375,7 @@ namespace LOFAR ...@@ -372,10 +375,7 @@ namespace LOFAR
(result.direction[i] * itsPositionDiffs[j]) / speedOfLight; (result.direction[i] * itsPositionDiffs[j]) / speedOfLight;
LOG_TRACE_CALC_STR(" [" << i << "]: " << itsDelaysAfterEnd[i]); LOG_TRACE_CALC_STR(" [" << i << "]: " << itsDelaysAfterEnd[i]);
} }
} }
} // namespace CS1 } // namespace CS1
} // namespace LOFAR } // namespace LOFAR
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment