CUDA-Q Platform¶
Operating System:
Terminal:
Shell:
Editor:
Package Manager:
Programming Language:
Database:
NVIDIA Libraries:
Extension:
Operating System:
Terminal:
Shell:
Editor:
Package Manager:
Programming Language:
Database:
NVIDIA Libraries:
Extension:
Operating System:
Terminal:
Shell:
Editor:
Package Manager:
Programming Language:
Database:
NVIDIA Libraries:
Extension:
Operating System:
Terminal:
Shell:
Editor:
Package Manager:
Programming Language:
Database:
NVIDIA Libraries:
Extension:
NVIDIA CUDA-Q is a platform for hybrid quantum-classical computing.
The platform consists of both a specification and a compiler NVQ++. It delivers a unified programming model designed for quantum processors (either actual or emulated) in a hybrid setting, that is, CPUs, GPUs, and QPUs working together.
Information about the supported simulation backends can be found here.
Initialization¶
For information on how to use the Initialization parameter, please refer to the Initialization: Bash Script and Initialization: PyPI Packages section of the documentation.
Run a Script in Batch Mode¶
The optional Batch mode parameter is used to run a Bash script (.sh
) when the job starts.
In this case the job ends immediately after the program runs.
Tutorials and Examples¶
To get started with CUDA Quantum and understand the programming and execution model, several examples and tutorials can be found in the default user's home folder.
For example, this command executes an implementation of a Bernstein-Vazirani algorithm:
$ nvq++ $HOME/examples/cpp/basics/bernstein_vazirani.cpp && ./a.out
The program will use GPU-acceleration if a suitable GPU has been detected. To confirm that the GPU acceleration works, one can increase the size of the secret string and pass the target as a command line argument:
$ nvq++ $HOME/examples/cpp/basics/bernstein_vazirani.cpp -DSIZE=25 --target nvidia && ./a.out
Contents