Skip to content

Commit

Permalink
Rename fields
Browse files Browse the repository at this point in the history
  • Loading branch information
Mythir committed Dec 16, 2024
1 parent 490549e commit a11df64
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion qiskit_quantuminspire/qi_backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def __init__(self, backend_type: BackendType, **kwargs: Any):
self._options = self._default_options()
self.set_options(shots=backend_type.default_number_of_shots)

if not backend_type.supports_shot_memory:
if not backend_type.supports_raw_data:
self._options.set_validator("memory", [False])

# Construct coupling map
Expand Down
6 changes: 3 additions & 3 deletions qiskit_quantuminspire/qi_jobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ async def job_run_sequence(
in_api_client,
file.id,
in_batch_job.id,
shot_memory_enabled=cast(bool, options.get("memory")),
raw_data_enabled=cast(bool, options.get("memory")),
number_of_shots=options.get("shots"),
)
circuit_data.job_id = job.id
Expand Down Expand Up @@ -188,15 +188,15 @@ async def _create_job(
api_client: ApiClient,
file_id: int,
batch_job_id: int,
shot_memory_enabled: bool,
raw_data_enabled: bool,
number_of_shots: Optional[int] = None,
) -> Job:
api_instance = JobsApi(api_client)
obj = JobIn(
file_id=file_id,
batch_job_id=batch_job_id,
number_of_shots=number_of_shots,
shot_memory_enabled=shot_memory_enabled,
raw_data_enabled=raw_data_enabled,
)
return await api_instance.create_job_jobs_post(obj)

Expand Down
2 changes: 1 addition & 1 deletion tests/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def create_backend_type(
infrastructure="QCI",
description="A Quantum Inspire backend",
native_gateset="",
supports_shot_memory=False,
supports_raw_data=False,
)


Expand Down
2 changes: 1 addition & 1 deletion tests/test_qi_backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def test_qi_backend_run_supports_shot_memory(mocker: MockerFixture) -> None:
job = MagicMock()
mocker.patch("qiskit_quantuminspire.qi_backend.QIJob", return_value=job)
backend_type = create_backend_type(max_number_of_shots=4096)
backend_type.supports_shot_memory = True
backend_type.supports_raw_data = True
qi_backend = QIBackend(backend_type=backend_type)

# Act
Expand Down

0 comments on commit a11df64

Please sign in to comment.