MCPcopy Create free account
hub / github.com/audeering/opensmile / powi

Function powi

scripts/modeltrain/libsvm-small/svm.cpp:24–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

22 memcpy((void *)dst,(void *)src,sizeof(T)*n);
23}
24inline double powi(double base, int times)
25{
26 double tmp = base, ret = 1.0;
27
28 for(int t=times; t>0; t/=2)
29 {
30 if(t%2==1) ret*=tmp;
31 tmp = tmp * tmp;
32 }
33 return ret;
34}
35#define INF HUGE_VAL
36#define TAU 1e-12
37#define Malloc(type,n) (type *)malloc((n)*sizeof(type))

Callers 2

kernel_polyMethod · 0.70
k_functionMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected