Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Tetragramm
GitHub Repository: Tetragramm/opencv
Path: blob/master/modules/core/src/hal_internal.hpp
16337 views
1
/*M///////////////////////////////////////////////////////////////////////////////////////
2
//
3
// IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
4
//
5
// By downloading, copying, installing or using the software you agree to this license.
6
// If you do not agree to this license, do not download, install,
7
// copy or use the software.
8
//
9
//
10
// License Agreement
11
// For Open Source Computer Vision Library
12
//
13
// Copyright (C) 2000-2008, Intel Corporation, all rights reserved.
14
// Copyright (C) 2009, Willow Garage Inc., all rights reserved.
15
// Copyright (C) 2013, OpenCV Foundation, all rights reserved.
16
// Copyright (C) 2015, Itseez Inc., all rights reserved.
17
// Third party copyrights are property of their respective owners.
18
//
19
// Redistribution and use in source and binary forms, with or without modification,
20
// are permitted provided that the following conditions are met:
21
//
22
// * Redistribution's of source code must retain the above copyright notice,
23
// this list of conditions and the following disclaimer.
24
//
25
// * Redistribution's in binary form must reproduce the above copyright notice,
26
// this list of conditions and the following disclaimer in the documentation
27
// and/or other materials provided with the distribution.
28
//
29
// * The name of the copyright holders may not be used to endorse or promote products
30
// derived from this software without specific prior written permission.
31
//
32
// This software is provided by the copyright holders and contributors "as is" and
33
// any express or implied warranties, including, but not limited to, the implied
34
// warranties of merchantability and fitness for a particular purpose are disclaimed.
35
// In no event shall the Intel Corporation or contributors be liable for any direct,
36
// indirect, incidental, special, exemplary, or consequential damages
37
// (including, but not limited to, procurement of substitute goods or services;
38
// loss of use, data, or profits; or business interruption) however caused
39
// and on any theory of liability, whether in contract, strict liability,
40
// or tort (including negligence or otherwise) arising in any way out of
41
// the use of this software, even if advised of the possibility of such damage.
42
//
43
//M*/
44
45
#ifndef OPENCV_CORE_HAL_INTERNAL_HPP
46
#define OPENCV_CORE_HAL_INTERNAL_HPP
47
48
#include "precomp.hpp"
49
50
#ifdef HAVE_LAPACK
51
52
int lapack_LU32f(float* a, size_t a_step, int m, float* b, size_t b_step, int n, int* info);
53
int lapack_LU64f(double* a, size_t a_step, int m, double* b, size_t b_step, int n, int* info);
54
int lapack_Cholesky32f(float* a, size_t a_step, int m, float* b, size_t b_step, int n, bool* info);
55
int lapack_Cholesky64f(double* a, size_t a_step, int m, double* b, size_t b_step, int n, bool* info);
56
int lapack_SVD32f(float* a, size_t a_step, float* w, float* u, size_t u_step, float* vt, size_t v_step, int m, int n, int flags);
57
int lapack_SVD64f(double* a, size_t a_step, double* w, double* u, size_t u_step, double* vt, size_t v_step, int m, int n, int flags);
58
int lapack_QR32f(float* src1, size_t src1_step, int m, int n, int k, float* src2, size_t src2_step, float* dst, int* info);
59
int lapack_QR64f(double* src1, size_t src1_step, int m, int n, int k, double* src2, size_t src2_step, double* dst, int* info);
60
int lapack_gemm32f(const float* src1, size_t src1_step, const float* src2, size_t src2_step,
61
float alpha, const float* src3, size_t src3_step, float beta, float* dst, size_t dst_step,
62
int m, int n, int k, int flags);
63
int lapack_gemm64f(const double* src1, size_t src1_step, const double* src2, size_t src2_step,
64
double alpha, const double* src3, size_t src3_step, double beta, double* dst, size_t dst_step,
65
int m, int n, int k, int flags);
66
int lapack_gemm32fc(const float* src1, size_t src1_step, const float* src2, size_t src2_step,
67
float alpha, const float* src3, size_t src3_step, float beta, float* dst, size_t dst_step,
68
int m, int n, int k, int flags);
69
int lapack_gemm64fc(const double* src1, size_t src1_step, const double* src2, size_t src2_step,
70
double alpha, const double* src3, size_t src3_step, double beta, double* dst, size_t dst_step,
71
int m, int n, int k, int flags);
72
73
#undef cv_hal_LU32f
74
#define cv_hal_LU32f lapack_LU32f
75
#undef cv_hal_LU64f
76
#define cv_hal_LU64f lapack_LU64f
77
78
#undef cv_hal_Cholesky32f
79
#define cv_hal_Cholesky32f lapack_Cholesky32f
80
#undef cv_hal_Cholesky64f
81
#define cv_hal_Cholesky64f lapack_Cholesky64f
82
83
#undef cv_hal_SVD32f
84
#define cv_hal_SVD32f lapack_SVD32f
85
#undef cv_hal_SVD64f
86
#define cv_hal_SVD64f lapack_SVD64f
87
88
#undef cv_hal_QR32f
89
#define cv_hal_QR32f lapack_QR32f
90
#undef cv_hal_QR64f
91
#define cv_hal_QR64f lapack_QR64f
92
93
#undef cv_hal_gemm32f
94
#define cv_hal_gemm32f lapack_gemm32f
95
#undef cv_hal_gemm64f
96
#define cv_hal_gemm64f lapack_gemm64f
97
#undef cv_hal_gemm32fc
98
#define cv_hal_gemm32fc lapack_gemm32fc
99
#undef cv_hal_gemm64fc
100
#define cv_hal_gemm64fc lapack_gemm64fc
101
102
#endif //HAVE_LAPACK
103
#endif //OPENCV_CORE_HAL_INTERNAL_HPP
104
105