Skip to content
Snippets Groups Projects
Commit be2832cb authored by Patrick Godwin's avatar Patrick Godwin
Browse files

gstlal_peakfinder.c: fixed issue in gstlal_peak_max_over_channels where...

gstlal_peakfinder.c: fixed issue in gstlal_peak_max_over_channels where peak_max was not stored correctly, producing nonsensical results
parent bb24e9ab
No related branches found
No related tags found
No related merge requests found
......@@ -213,7 +213,7 @@ int gstlal_peak_max_over_channels(struct gstlal_peak_state *state)
{
if(fabsf(state->values.as_float[i]) > max_val)
{
max_val = state->values.as_float[i];
max_val = fabsf(state->values.as_float[i]);
out = i;
}
}
......@@ -228,7 +228,7 @@ int gstlal_peak_max_over_channels(struct gstlal_peak_state *state)
{
if(fabs(state->values.as_double[i]) > max_val)
{
max_val = state->values.as_double[i];
max_val = fabs(state->values.as_double[i]);
out = i;
}
}
......@@ -243,7 +243,7 @@ int gstlal_peak_max_over_channels(struct gstlal_peak_state *state)
{
if(cabsf(state->values.as_float_complex[i]) > max_val)
{
max_val = state->values.as_float_complex[i];
max_val = cabsf(state->values.as_float_complex[i]);
out = i;
}
}
......@@ -258,7 +258,7 @@ int gstlal_peak_max_over_channels(struct gstlal_peak_state *state)
{
if(cabs(state->values.as_double_complex[i]) > max_val)
{
max_val = state->values.as_double_complex[i];
max_val = cabs(state->values.as_double_complex[i]);
out = i;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment