Created
September 4, 2014 05:32
-
-
Save agibsonccc/8bdb733f57525dbdda6e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public static IComplexNDArray gemm(IComplexNDArray A, IComplexNDArray B, IComplexNDArray C, | |
| float Alpha, float Beta) { | |
| JCublasNDArray cA = (JCublasNDArray) A; | |
| JCublasNDArray cB = (JCublasNDArray) B; | |
| JCublasNDArray cC = (JCublasNDArray) C; | |
| cuDoubleComplex alpha = cuDoubleComplex.cuCmplx(Alpha,0); | |
| cuDoubleComplex beta = cuDoubleComplex.cuCmplx(Beta,0); | |
| JCublas.cublasZgemm( | |
| 'n', //trans | |
| 'n', | |
| A.rows(), // m | |
| B.columns(), // n | |
| B.rows(), //k, | |
| alpha, | |
| cA.pointer(), // A | |
| A.rows(), // lda | |
| cB.pointer(), // x | |
| B.rows(), // incx | |
| beta, // beta | |
| cC.pointer(), // y | |
| C.rows()); // incy | |
| cC.getData(); | |
| return C; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment