lasp/beamforming/config.pxi.in

50 lines
1.1 KiB
Cython
Raw Normal View History

2018-01-29 15:14:50 +00:00
import numpy as np
cimport numpy as np
from libcpp cimport bool
DEF ASCEE_FLOAT = "@ASCEE_FLOAT@"
IF ASCEE_FLOAT == "double":
ctypedef double d
ctypedef double complex c
NUMPY_FLOAT_TYPE = np.float64
NUMPY_COMPLEX_TYPE = np.complex128
ELSE:
ctypedef float d
ctypedef float complex c
NUMPY_FLOAT_TYPE = np.float32
NUMPY_COMPLEX_TYPE = np.complex128
ctypedef size_t us
cdef extern from "ascee_tracer.h":
void setTracerLevel(int)
cdef extern from "ascee_math.h":
2018-01-29 15:14:50 +00:00
ctypedef struct dmat:
d* data
d** col_ptrs
2018-01-29 15:14:50 +00:00
us n_cols,n_rows
ctypedef struct cmat:
c* data
c** col_ptrs
2018-01-29 15:14:50 +00:00
us n_cols,n_rows
dmat dmat_foreign(us n_rows,
us n_cols,
d* data)
cmat cmat_foreign(us n_rows,
us n_cols,
c* data)
cmat cmat_alloc(us n_rows,us n_cols)
dmat dmat_alloc(us n_rows,us n_cols)
void dmat_free(dmat*)
void cmat_free(cmat*)
void cmat_copy(cmat* to,cmat* from_)
cdef extern from "ascee_tracer.h":
void clearScreen()