Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ORNL Quantum Computing Institute
xacc
Commits
b741a1f8
Commit
b741a1f8
authored
May 19, 2020
by
Daniel Strano
Committed by
WrathfulSpatula
May 19, 2020
Browse files
Qrack plugin: add accelerator to docs
Signed-off-by:
WrathfulSpatula
<
stranoj@gmail.com
>
parent
11aa5ac7
Changes
1
Hide whitespace changes
Inline
Side-by-side
docs/source/extensions.rst
View file @
b741a1f8
...
...
@@ -509,6 +509,32 @@ To use automatic gate-to-pulse functionality, we need to load a pulse library to
For
more
information
,
please
check
out
these
`
examples
<
https
://
github
.
com
/
ORNL
-
QCI
/
QuaC
/
tree
/
xacc
-
integration
/
xacc_examples
/
python
>`
_
.
Qrack
+++++
The
`
vm6502q
/
qrack
<
https
://
github
.
com
/
vm6502q
/
qrack
>`
_
simulator
-
based
accelerator
provides
optional
OpenCL
-
based
GPU
acceleration
,
as
well
as
a
novel
simulator
optimization
layer
.
..
code
::
cpp
auto
qrk
=
xacc
::
getAccelerator
(
"qrack"
,
{
std
::
make_pair
(
"shots"
,
2048
)});
By
default
,
it
selects
initialization
parameters
that
are
commonly
best
for
a
wide
range
of
use
cases
.
However
,
it
is
highly
configurable
through
a
number
of
exposed
parameters
:
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
Initialization
Parameter
|
Parameter
Description
|
type
|
default
|
+=============================+========================================================================+=============+==========================+
|
shots
|
Number
of
iterations
to
repeat
the
circuit
for
|
int
|
-
1
(
Z
-
expectation
only
)
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
use_opencl
|
Use
OpenCL
acceleration
if
available
,
(
otherwise
native
C
++
11
)
|
bool
|
true
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
use_qunit
|
Turn
on
the
novel
optimization
layer
,
(
otherwise
"Schrödinger method"
)
|
bool
|
true
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
device_id
|
The
(
Qrack
)
device
ID
number
of
the
OpenCL
accelerator
to
use
|
int
|
-
1
(
auto
-
select
)
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
do_normalize
|
Enable
small
norm
probability
amplitude
flooring
and
normalization
|
bool
|
true
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
|
zero_threshold
|
Norm
threshold
for
clamping
probability
amplitudes
to
0
|
double
|
1e-14
/
1e-30
float
/
double
|
+-----------------------------+------------------------------------------------------------------------+-------------+--------------------------+
Algorithms
----------
XACC
exposes
hybrid
quantum
-
classical
Algorithm
implementations
for
the
variational
quantum
eigensolver
(
VQE
),
data
-
driven
...
...
@@ -1267,4 +1293,4 @@ Example:
vqe
->
execute
(
buffer
);
//
Expected
result
:
-
1.74886
std
::
cout
<<
"Energy: "
<<
(*
buffer
)[
"opt-val"
].
as
<
double
>()
<<
"
\n
"
;
}
\ No newline at end of file
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment