You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you wrap the final value in _handle_readout_bug below, the test will pass.
def_handle_readout_bug(final_value: int):
iffinal_value<0:
# somewhere up the stack, values are being interpreted as signed-magnitude.# Here we correct that by flipping the bits and adding 1 to get the correct# two's complement value.return (final_value^ (2**47-1)) +1returnfinal_value
Info:
$ poetry run python --version
Python 3.9.19
$ poetry show pyquil
name : pyquil
version : 4.9.2
description : A Python library for creating Quantum Instruction Language (Quil) programs.
$ poetry show qcs-sdk-python
name : qcs-sdk-python
version : 0.17.6
description : Python interface for the QCS Rust SDK
The text was updated successfully, but these errors were encountered:
erichulburd
changed the title
Negative Integer Values are improperly returned from on ExecutionResults
Negative Integer Values are improperly returned on ExecutionResultsMay 8, 2024
The following test fails:
Output:
If you wrap the final value in
_handle_readout_bug
below, the test will pass.Info:
The text was updated successfully, but these errors were encountered: