MCPcopy Create free account
hub / github.com/pydata/numexpr / nc_real

Function nc_real

numexpr3/complex_functions.hpp:44–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42// abs() has been changed to return npy_float and npy_double, like NumPy
43
44static void
45nc_real( npy_intp n, npy_complex64 *x, npy_intp sb1, npy_float32 *r)
46{
47 if( sb1 == sizeof(npy_complex64) ) { // Aligned
48 for( npy_intp I = 0; I < n; I++ ) {
49 r[I] = x[I].real;
50 }
51 }
52 else {
53 sb1 /= sizeof(npy_complex64);
54 for( npy_intp I = 0; I < n; I++ ) {
55 r[I] = x[I*sb1].real;
56 }
57 }
58
59}
60
61static void
62nc_real( npy_intp n, npy_complex128 *x, npy_intp sb1, npy_float64 *r)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…