Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
Fixed tab of documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
merav-aharoni committed Jul 27, 2023
1 parent 9f97104 commit 577e3f9
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions qiskit_ibm_provider/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,20 @@ class Session:
For example::
from qiskit.test.reference_circuits import ReferenceCircuits
from qiskit_ibm_provider import IBMProvider
from qiskit_ibm_provider.session import Session
circ = ReferenceCircuits.bell()
backend = "ibmq_qasm_simulator"
with Session(backend_name=backend) as session:
provider = IBMProvider(session=session)
job = provider.get_backend(name=backend).run(circ)
print(f"Job ID: {job.job_id()}")
print(f"Result: {job.result()}")
# Close the session only if all jobs are finished and
# you don't need to run more in the session.
provider.close_session()
from qiskit.test.reference_circuits import ReferenceCircuits
from qiskit_ibm_provider import IBMProvider
from qiskit_ibm_provider.session import Session
circ = ReferenceCircuits.bell()
backend = "ibmq_qasm_simulator"
with Session(backend_name=backend) as session:
provider = IBMProvider(session=session)
job = provider.get_backend(name=backend).run(circ)
print(f"Job ID: {job.job_id()}")
print(f"Result: {job.result()}")
# Close the session only if all jobs are finished and
# you don't need to run more in the session.
provider.close_session()
"""

def __init__(
Expand Down

0 comments on commit 577e3f9

Please sign in to comment.