Skip to content

Commit

Permalink
support py3.7 (#46)
Browse files Browse the repository at this point in the history
* support py3.7

* update

* Update requirements.txt

* Update requirements.txt

* update

* reorder

* bump minor version
  • Loading branch information
singular-value authored Sep 1, 2022
1 parent bd19d18 commit 39faefd
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion dev-requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
general-superstaq[dev]==0.2.0
general-superstaq[dev]~=0.2.5
8 changes: 4 additions & 4 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cirq-superstaq==0.2.0
cirq~=0.15.0
qiskit-superstaq==0.2.0
scikit-learn~=1.1.1
cirq~=1.0.0
cirq-superstaq~=0.2.3
qiskit-superstaq~=0.2.4
scikit-learn~=1.0 # supports python 3.7
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
url="https://github.com/SupertechLabs/SupermarQ",
author="Super.tech",
author_email="[email protected]",
python_requires=(">=3.8.0"),
python_requires=(">=3.7.0"),
install_requires=requirements,
extras_require={"dev": dev_requirements},
license="Apache 2",
Expand Down
2 changes: 1 addition & 1 deletion supermarq/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.0.4"
__version__ = "0.1.0"
2 changes: 1 addition & 1 deletion supermarq/simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

def get_ideal_counts(circuit: cirq.Circuit) -> collections.Counter:
ideal_counts = {}
for i, amplitude in enumerate(circuit.final_state_vector()):
for i, amplitude in enumerate(circuit.final_state_vector(ignore_terminal_measurements=True)):
bitstring = f"{i:>0{len(circuit.all_qubits())}b}"
probability = np.abs(amplitude) ** 2
ideal_counts[bitstring] = probability
Expand Down

0 comments on commit 39faefd

Please sign in to comment.