MCPcopy Create free account
hub / github.com/NVIDIA/cuda-quantum / complex_np_use_real

Function complex_np_use_real

python/tests/kernel/test_kernel_complex.py:159–161  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

157 # Use a complex inside np in a kernel (sin)
158 @cudaq.kernel
159 def complex_np_use_real() -> float:
160 v = np.sin(np.pi / 2 + 0j)
161 return v.real
162
163 t = np.sin(np.pi / 2 + 0j).real
164 assert is_close(t, complex_np_use_real())

Callers 3

test_complex_useFunction · 0.85
test_np_complex128_useFunction · 0.85
test_np_complex64_useFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected