bloqade.qbraid.target.qBraid
← Module overview
class
method
source
classqBraid¶source
bloqade.qbraid.target.qBraid
qBraid target for Bloqade kernels.
Signature
class qBraid(*, allow_parallel: bool = False, allow_global: bool = False, provider: QbraidProvider, qelib1: bool = True)qBraid target that accepts a Bloqade kernel and submits the kernel to the QuEra simulator hosted on qBraid. A QbraidJob is obtainable
that then lets you query the status of the submitted program on the simulator as well
as obtain results.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
allow_parallel | bool | False | Allow parallel gate in the resulting QASM2 AST. Defaults to `False`. In the case its False, and the input kernel uses parallel gates, they will get rewrite into uop gates. |
allow_global | bool | False | Allow global gate in the resulting QASM2 AST. Defaults to `False`. In the case its False, and the input kernel uses global gates, they will get rewrite into parallel gates. If both `allow_parallel` and `allow_global` are False, the input kernel will be rewritten to use uop gates. |
provider | QbraidProvider | required | Qbraid-provided object to allow submission of the kernel to the QuEra simulator. |
qelib1 | bool | True | Include the `include "qelib1.inc"` line in the resulting QASM2 AST that's submitted to qBraid. Defaults to `True`. |
Attributes
| Name | Type | Default | Description |
|---|---|---|---|
qelib1 | — | qelib1 | |
provider | — | provider | |
allow_parallel | — | allow_parallel | |
allow_global | — | allow_global |
methodemit¶source
bloqade.qbraid.target.qBraid.emit
Signature
def emit(method: ir.Method, shots: Optional[int] = None, tags: Optional[dict[str, str]] = None) -> Union[QbraidJob, list[QbraidJob]]Submit the Bloqade kernel to the QuEra simulator on qBraid.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
method | ir.Method | required | The kernel to submit to qBraid. |
shots | Optional[int] | None | (Optional[int]): Number of times to run the kernel. Defaults to None. |
tags | Optional[dict[str, str]] | None | (Optional[dict[str,str]]): A dictionary of tags to associate with the Job. |
Returns
Union[QbraidJob, list[QbraidJob]]An object you can query for the status of your submission as well as obtain simulator results from.