Skip to content

Commit

Permalink
Apply review comment from Dysco repos
Browse files Browse the repository at this point in the history
  • Loading branch information
aroffringa committed Apr 19, 2024
1 parent e5e6a00 commit bbc7c79
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tables/Dysco/rftimeblockencoder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ void RFTimeBlockEncoder::maximizeChannels(std::vector<DBufferRow> &data, float *
double largest_component = 0.0;
for (const DBufferRow &row : data) {
const std::complex<double> *ptr = &row.visibilities[visIndex];
double local_max = std::max(std::max(ptr->real(), ptr->imag()),
-std::min(ptr->real(), ptr->imag()));
const double local_max = std::max(std::fabs(ptr->real()), std::fabs(ptr->imag()));
if (std::isfinite(local_max) && local_max > largest_component)
largest_component = local_max;
}
Expand Down

0 comments on commit bbc7c79

Please sign in to comment.