0 41 0
Upgrade Instructions
- Python SDK
- The IDE upgrades automatically.
Enhancement
- Hardware-aware synthesis
will now use the Solovay-Kitaev algorithm to approximate
single-qubit gates when the basis gate set is a specific variation of
Clifford + T (
X
,Z
,H
,T
,CX
, andCCX
). qsvt
function was added to the function library. See Quantum Singular Value Transformation.- A tutorial on discrete quantum walks was added to the tutorials library. See Discrete Quantum Walk.
- SDK: Quantum functions (
@qfunc
) can be recursive. - SDK: PauliTerm can be used to declare a hamiltonian.
hamiltonian = [ PauliTerm(pauli=[Pauli.I], coefficient=1), PauliTerm(pauli=[Pauli.Z, Pauli.X], coefficient=2), ]
- Introducing ExecutionSession which will allow choosing the execution primitive in the SDK without the need of changing/synthesizing the quantum program once again.
model = create_model(main)
qprog = synthesize(model)
preferences = ExecutionPreferences(num_shots=1200)
execution_session = ExecutionSession(qprog, preferences)
# if the quantum program does not need any execution paramters:
execution_session.sample()
# if the quantum program needs execution parameters:
execution_session.sample({"phi": 1})
# if multiple samples are needed:
execution_session.batch_sample([{"phi": 1}, {"phi": 2}, {"phi": 3}])
# if an estimation is needed without execution parameters:
hamiltonian = [
PauliTerm(pauli=[Pauli.I], coefficient=1),
PauliTerm(pauli=[Pauli.Z], coefficient=2),
]
execution_parameters.estimate(hamiltonian)
# if an estimation is needed with execution paramters:
execution_parameters.estimate(hamiltonian, {"theta": 1})
# if multiple estimations are needed:
execution_parameters.batch_estimate(hamiltonian, [{"theta": 1}, {"theta": 2}])
- A Qmod library reference, with usage examples for built-in and open library functions, can now be found in the function menu.
Interface Changes
- SDK: In
execute_qnn
, the optional argumentobservables
of typePauliOperators
has been replaced with the optional argumentobservable
of typePauliOperator
. -
Documentation: The structure and content have the classiq documentation have been changed signficantly with the following new structure:
- Classiq 101
- Explore
- Read
- Practice
- Reference Manual
- Release Notes
The old User Guide
chapter from the previous documentation can be found in the new Reference Manual.
Deprecations
-
SDK: The
quantum_if
operation and the oldcontrol
syntax have been removed. -
quantum_if
is removed. Usecontrol
instead. control(operand, ctrl)
is no longer supported. Usecontrol(ctrl, operand)
instead.-
control(n, operand)
does not support quantum numeric variables (n
). Instead, use abind
operation to castn
into a quantum array, or comparen
to an integer explicitly (e.g.,n == 7
). -
SDK: The
QParam
type has been removed. -
Instead of
QParam[int]
, useCInt
. - Instead of
QParam[float]
, useCReal
. - Instead of
QParam[bool]
, useCBool
. - Instead of
QParam[List[...]]
, useCArray[...]
. -
Instead of
QParam[Array[..., size]]
, useCArray[..., size]
. -
Native Qmod: Accessing quantum variable properties (e.g.,
qbv.len
orn.is_signed
) via function call syntax (len(qbv)
,is_signed(qbv)
) is no longer supported. -
The field
optimizer_preferences
ofExecutionPreferences
has been removed. -
The function
set_initial_values
has been removed.
IDE
- "Slack" and "Learn More" links were moved from the side drawer to the IDE header. New links were added as well: Community, User Guide.
- Allow visualization of larger circuits and prolong the timeout for visualization
- Users can now download a LaTeX format of their quantum programs directly from the IDE, allowing for easy sharing, publication, and presentation of their work.
- Cookies settings are now available to adjust the given consent at any time.
Bug fixes
- "selected example not found" error when opening the IDE
- Resetting now clears preferences form instead of initializing from cache on the model page
- Naming for exported files on the Graphical Editor
- State vector measurement results ordering
- Parameter names in lambda expressions don't have to match the parameter names in operand declarations:
qfunc my_H(qb: qbit) {
H(qb);
}
...
apply_to_all<my_H>(qba); // used to throw an error since "qb" != "target"
@qfunc
def my_H(qb: QBit) -> None:
H(qb)
...
apply_to_all(my_H, qba) # used to throw an error since "qb" != "target"