18 #ifndef TMVA_DNN_ARCHITECTURES_CPU_BLAS 19 #define TMVA_DNN_ARCHITECTURES_CPU_BLAS 25 extern "C" void saxpy_(
const int *
n,
const float * alpha,
const float *
x,
26 const int * incx,
float *
y,
const int * incy);
27 extern "C" void daxpy_(
const int *
n,
const double * alpha,
const double *
x,
28 const int * incx,
double *
y,
const int * incy);
29 extern "C" void sger_(
const int *
m,
const int *
n,
const float * alpha,
30 const float *
x,
const int * incx,
31 const float *
y,
const int * incy,
32 float *
A,
const int * lda);
33 extern "C" void dger_(
const int *
m,
const int *
n,
const double * alpha,
34 const double *
x,
const int * incx,
35 const double *
y,
const int * incy,
36 double *
A,
const int * lda);
37 extern "C" void sgemv_(
const char * trans,
const int *
m,
const int *
n,
38 const float * alpha,
const float *
A,
const int * lda,
39 const float *
x,
const int * incx,
40 const float *
beta,
float *
y,
const int * incy);
41 extern "C" void dgemv_(
const char * trans,
const int *
m,
const int *
n,
42 const double * alpha,
const double *
A,
const int * lda,
43 const double *
x,
const int * incx,
44 const double *
beta,
double *
y,
const int * incy);
45 extern "C" void dgemm_(
const char * transa,
const char * transb,
46 const int *
m,
const int *
n,
const int * k,
47 const double * alpha,
const double *
A,
const int * lda,
48 const double *
B,
const int * ldb,
const double *
beta,
49 double *
C,
const int * ldc);
50 extern "C" void sgemm_(
const char * transa,
const char * transb,
51 const int *
m,
const int *
n,
const int * k,
52 const float * alpha,
const float *
A,
const int * lda,
53 const float *
B,
const int * ldb,
const float *
beta,
54 float *
C,
const int * ldc);
66 template <
typename Real_t>
67 inline void Axpy(
const int *
n,
const Real_t * alpha,
68 const Real_t *
x,
const int * incx,
72 template <
typename Real_t>
73 inline void Gemv(
const char *trans,
const int *
m,
const int * n,
75 const Real_t * x,
const int * incx,
79 template <
typename Real_t>
80 inline void Gemm(
const char *transa,
const char *transb,
81 const int * m,
const int * n,
const int* k,
87 template <
typename Real_t>
88 inline void Ger(
const int * m,
const int * n,
const Real_t * alpha,
89 const Real_t * x,
const int * incx,
90 const Real_t * y,
const int * incy,
91 Real_t * A,
const int * lda);
97 const double *
x,
const int * incx,
98 double *
y,
const int * incy)
100 daxpy_(n, alpha, x, incx, y, incy);
105 const float *
x,
const int * incx,
106 float *
y,
const int * incy)
108 saxpy_(n, alpha, x, incx, y, incy);
113 const double * alpha,
const double *
A,
const int * lda,
114 const double *
x,
const int * incx,
115 const double *
beta,
double *
y,
const int * incy)
117 dgemv_(trans, m, n, alpha, A, lda, x, incx, beta, y, incy);
122 const float * alpha,
const float *
A,
const int * lda,
123 const float *
x,
const int * incx,
124 const float *
beta,
float *
y,
const int * incy)
126 sgemv_(trans, m, n, alpha, A, lda, x, incx, beta, y, incy);
131 const int *
m,
const int *
n,
const int* k,
132 const double * alpha,
const double *
A,
const int * lda,
133 const double *
B,
const int * ldb,
const double *
beta,
134 double *
C,
const int * ldc)
136 dgemm_(transa, transb, m, n, k, alpha, A, lda, B, ldb, beta, C, ldc);
141 const int *
m,
const int *
n,
const int* k,
142 const float * alpha,
const float *
A,
const int * lda,
143 const float *
B,
const int * ldb,
const float *
beta,
144 float *
C,
const int * ldc)
146 sgemm_(transa, transb, m, n, k, alpha, A, lda, B, ldb, beta, C, ldc);
151 const double *
x,
const int * incx,
152 const double *
y,
const int * incy,
153 double *
A,
const int * lda)
155 dger_(m, n, alpha, x, incx, y, incy, A, lda);
159 inline void Ger<float>(
const int *
m,
const int *
n,
const float * alpha,
160 const float *
x,
const int * incx,
161 const float *
y,
const int * incy,
162 float *
A,
const int * lda)
164 sger_(m, n, alpha, x, incx, y, incy, A, lda);
void sgemv_(const char *trans, const int *m, const int *n, const float *alpha, const float *A, const int *lda, const float *x, const int *incx, const float *beta, float *y, const int *incy)
void Axpy< double >(const int *n, const double *alpha, const double *x, const int *incx, double *y, const int *incy)
void Ger(const int *m, const int *n, const Real_t *alpha, const Real_t *x, const int *incx, const Real_t *y, const int *incy, Real_t *A, const int *lda)
Add the outer product of x and y to the matrix A.
void Ger< float >(const int *m, const int *n, const float *alpha, const float *x, const int *incx, const float *y, const int *incy, float *A, const int *lda)
void Axpy< float >(const int *n, const float *alpha, const float *x, const int *incx, float *y, const int *incy)
void saxpy_(const int *n, const float *alpha, const float *x, const int *incx, float *y, const int *incy)
double beta(double x, double y)
Calculates the beta function.
void dgemm_(const char *transa, const char *transb, const int *m, const int *n, const int *k, const double *alpha, const double *A, const int *lda, const double *B, const int *ldb, const double *beta, double *C, const int *ldc)
void Gemm(const char *transa, const char *transb, const int *m, const int *n, const int *k, const Real_t *alpha, const Real_t *A, const int *lda, const Real_t *B, const int *ldb, const Real_t *beta, Real_t *C, const int *ldc)
Multiply the matrix A with the matrix B and store the result in C.
void Ger< double >(const int *m, const int *n, const double *alpha, const double *x, const int *incx, const double *y, const int *incy, double *A, const int *lda)
void dger_(const int *m, const int *n, const double *alpha, const double *x, const int *incx, const double *y, const int *incy, double *A, const int *lda)
void Gemm< float >(const char *transa, const char *transb, const int *m, const int *n, const int *k, const float *alpha, const float *A, const int *lda, const float *B, const int *ldb, const float *beta, float *C, const int *ldc)
void Gemv< float >(const char *trans, const int *m, const int *n, const float *alpha, const float *A, const int *lda, const float *x, const int *incx, const float *beta, float *y, const int *incy)
void Axpy(const int *n, const Real_t *alpha, const Real_t *x, const int *incx, Real_t *y, const int *incy)
Add the vector x scaled by alpha to y scaled by .
void Gemv(const char *trans, const int *m, const int *n, const Real_t *alpha, const Real_t *A, const int *lda, const Real_t *x, const int *incx, const Real_t *beta, Real_t *y, const int *incy)
Multiply the vector x with the matrix A and store the result in y.
void Gemm< double >(const char *transa, const char *transb, const int *m, const int *n, const int *k, const double *alpha, const double *A, const int *lda, const double *B, const int *ldb, const double *beta, double *C, const int *ldc)
void Gemv< double >(const char *trans, const int *m, const int *n, const double *alpha, const double *A, const int *lda, const double *x, const int *incx, const double *beta, double *y, const int *incy)
Abstract ClassifierFactory template that handles arbitrary types.
void dgemv_(const char *trans, const int *m, const int *n, const double *alpha, const double *A, const int *lda, const double *x, const int *incx, const double *beta, double *y, const int *incy)
void sgemm_(const char *transa, const char *transb, const int *m, const int *n, const int *k, const float *alpha, const float *A, const int *lda, const float *B, const int *ldb, const float *beta, float *C, const int *ldc)
void daxpy_(const int *n, const double *alpha, const double *x, const int *incx, double *y, const int *incy)
void sger_(const int *m, const int *n, const float *alpha, const float *x, const int *incx, const float *y, const int *incy, float *A, const int *lda)