mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-09-19 21:06:42 +00:00
lavu/lls: use ff_scalarproduct_double_c()
This commit is contained in:
parent
98405d28fa
commit
73c278d270
@ -30,6 +30,7 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#include "attributes.h"
|
#include "attributes.h"
|
||||||
|
#include "float_dsp.h"
|
||||||
#include "lls.h"
|
#include "lls.h"
|
||||||
|
|
||||||
static void update_lls(LLSModel *m, const double *var)
|
static void update_lls(LLSModel *m, const double *var)
|
||||||
@ -102,13 +103,7 @@ void avpriv_solve_lls(LLSModel *m, double threshold, unsigned short min_order)
|
|||||||
|
|
||||||
static double evaluate_lls(LLSModel *m, const double *param, int order)
|
static double evaluate_lls(LLSModel *m, const double *param, int order)
|
||||||
{
|
{
|
||||||
int i;
|
return ff_scalarproduct_double_c(m->coeff[order], param, order + 1);
|
||||||
double out = 0;
|
|
||||||
|
|
||||||
for (i = 0; i <= order; i++)
|
|
||||||
out += param[i] * m->coeff[order][i];
|
|
||||||
|
|
||||||
return out;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
av_cold void avpriv_init_lls(LLSModel *m, int indep_count)
|
av_cold void avpriv_init_lls(LLSModel *m, int indep_count)
|
||||||
|
Loading…
Reference in New Issue
Block a user