CUDA support for Yao.jl.
We are in an early-release beta. Expect some adventures and rough edges.
CuYao is a Julia Language package. It provides CUDA support for Yao.jl. To install CuYao, please open Julia's interactive session (known as REPL) and press ] key in the REPL to use the package mode, then type the following command
For stable release
pkg> add CuYao
For current master
pkg> add CuYao#master
You don't need to install Yao if you have CuYao
installed. They share the same API except CUDA backend.
For documentation of Yao, please refer to documentation (stable).
CuYao.jl
provides only two extra APIs, reg |> cu
to upload a register to GPU, and cureg |> cpu
to download a register to CPU.
To start, see the following example
using CuYao
cureg = rand_state(9; nbatch=1000) |> cu
cureg |> put(9, 2=>Z)
measure!(cureg |> addbits!(1) |> focus!(4,1,3))
cureg |> relax!(4,1,3) |> cpu
- general U(N) gate
- general U(1) gate
- better X, Y, Z gate
- better T, S gate
- SWAP gate
- better control gates
- BP diff blocks
- measure!, measure_reset!, measure_remove!, select
- addbit!
- insert_qubit!
- focus!, relax!
- join
- density_matrix
- statistic functional diff blocks
- expect for statistic functional
This project is an effort of QuantumBFS, an open source organization for quantum science. Yao is currently maintained by Xiu-Zhe (Roger) Luo and Jin-Guo Liu with contributions from open source community. All the contributors are listed in the contributors.
CuYao is released under the Apache 2 license.