Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
98d9703d
Commit
98d9703d
authored
Jul 18, 2018
by
Davis King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed cblas conflicts in some environments.
parent
4c816be0
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
13 deletions
+16
-13
cblas_constants.h
dlib/matrix/cblas_constants.h
+12
-2
matrix_blas_bindings.h
dlib/matrix/matrix_blas_bindings.h
+2
-5
matrix_trsm.h
dlib/matrix/matrix_trsm.h
+2
-6
No files found.
dlib/matrix/cblas_constants.h
View file @
98d9703d
...
...
@@ -3,7 +3,17 @@
#ifndef DLIB_CBLAS_CONSTAnTS_Hh_
#define DLIB_CBLAS_CONSTAnTS_Hh_
#ifndef CBLAS_H
#if !(defined(__GSL_CBLAS_H__) || defined(CBLAS_H))
// Setting this tells other headers to define their own copy of the cblas API so we can
// call it. We only do this if some other cblas API hasn't already been included.
#define DLIB_DEFINE_CBLAS_API
#ifndef CBLAS_INT_TYPE
#define CBLAS_INT_TYPE int
#endif
namespace
dlib
{
namespace
blas_bindings
...
...
@@ -16,7 +26,7 @@ namespace dlib
}
}
#endif
// if not CBLAS_H
#endif
#endif // DLIB_CBLAS_CONSTAnTS_Hh_
dlib/matrix/matrix_blas_bindings.h
View file @
98d9703d
...
...
@@ -46,12 +46,9 @@ namespace dlib
#define DLIB_TEST_BLAS_BINDING_SCAL
#endif
#if
ndef CBLAS_H
#if
def DLIB_DEFINE_CBLAS_API
extern
"C"
{
#ifndef CBLAS_INT_TYPE
#define CBLAS_INT_TYPE int
#endif
// Here we declare the prototypes for the CBLAS calls used by the BLAS bindings below
void
cblas_saxpy
(
const
CBLAS_INT_TYPE
N
,
const
float
alpha
,
const
float
*
X
,
...
...
@@ -139,7 +136,7 @@ namespace dlib
const
void
*
alpha
,
const
void
*
X
,
const
CBLAS_INT_TYPE
incX
,
const
void
*
Y
,
const
CBLAS_INT_TYPE
incY
,
void
*
A
,
const
CBLAS_INT_TYPE
lda
);
}
#endif // if
not CBLAS_H
#endif // if
DLIB_DEFINE_CBLAS_API
// ----------------------------------------------------------------------------------------
// ----------------------------------------------------------------------------------------
...
...
dlib/matrix/matrix_trsm.h
View file @
98d9703d
...
...
@@ -10,11 +10,7 @@ namespace dlib
namespace
blas_bindings
{
#ifdef DLIB_USE_BLAS
#ifndef CBLAS_H
#ifndef CBLAS_INT_TYPE
#define CBLAS_INT_TYPE int
#endif
#ifdef DLIB_DEFINE_CBLAS_API
extern
"C"
{
void
cblas_strsm
(
const
CBLAS_ORDER
Order
,
const
CBLAS_SIDE
Side
,
...
...
@@ -29,7 +25,7 @@ namespace dlib
const
double
alpha
,
const
double
*
A
,
const
CBLAS_INT_TYPE
lda
,
double
*
B
,
const
CBLAS_INT_TYPE
ldb
);
}
#endif // if
not CBLAS_H
#endif // if
DLIB_DEFINE_CBLAS_API
#endif // if DLIB_USE_BLAS
// ------------------------------------------------------------------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment