Skip to main content

Fire Opal RIKEN Client

This is the Fire Opal client integration for RIKEN quantum computing infrastructure using a gRPC client.

Architecture Overview

  • Client: Qiskit SamplerV2 implementation that sends circuits to Fire Opal server for optimization
  • Server: gRPC service that performs Fire Opal preprocessing/postprocessing

Installation

Choose the version that matches where you are logged in:

  • Fugaku: install the sqc version.
  • R-CCS cloud: install the ibm version.

Fugaku

Complete these steps before you install:

  1. Create a JHPC Quantum account. Sign up here: https://idp.qc.r-ccs.riken.jp/realms/jhpc-quantum/account
  2. Set up and install your CA certificate and JWT token in your Fugaku home directory. The JWT token must be located at $HOME/.sqc_rpc_sched/jwt.token.
  3. Set up your Python environment by following this guide: https://github.com/jhpc-quantum/documents/blob/main/Qiskit_JHPC_Quantum_user_guide.md

After you finish the steps above, install the sqc version:

pip install 'qctrl-fire-opal-riken-client[sqc]'

R-CCS cloud

The steps above are not required for R-CCS cloud. Install the ibm version:

pip install 'qctrl-fire-opal-riken-client[ibm]'

Usage

Here is a small example of how to use the Fire Opal RIKEN client with Qiskit. This communicates with a gRPC server to perform Fire Opal optimizations on a quantum circuit before executing it. Once the job is complete, post-processed results are returned from the job.result() call.

The only difference between Fugaku (sqc) and R-CCS cloud (ibm) is how the QiskitRuntimeService channel and backend are set up, as noted in the comments below.

from qiskit import QuantumCircuit
from fireopalrikenclient.sampler import FireOpalSampler
from qiskit_ibm_runtime import QiskitRuntimeService

# Create circuit.
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()

# Create sampler with Fire Opal preprocessing.
#
# On Fugaku (`sqc`), use the `jhpc_quantum` channel and the `ibm_sqc` backend.
# No `token` or `instance` is needed here, since those are provided by your
# SQC environment setup.
service = QiskitRuntimeService(channel="jhpc_quantum")
sampler = FireOpalSampler(mode=service.backend("ibm_sqc"))
#
# On R-CCS cloud (`ibm`), use the `ibm_quantum_platform` channel and the
# `ibm_kobe` backend. Replace `token` and `instance` with your `ibm_kobe`
# credentials provided by RIKEN.
# service = QiskitRuntimeService(token="...", instance="...", channel="ibm_quantum_platform")
# sampler = FireOpalSampler(mode=service.backend("ibm_kobe"))

# Run circuit with 1024 shots using Fire Opal optimization.
sampler_pub = (circuit, None, 1024)
job = sampler.run([sampler_pub])
result = job.result()

# Access the results
print(f"Number of pub results: {len(result)}")
print(f"Metadata: {result.metadata}")

# Access individual pub results by iterating over the result
for i, pub_result in enumerate(result):
    print(f"Pub {i}: {pub_result}")

# Or access a single pub result directly by index
print(f"First pub result: {result[0]}")

Metadata

Release files for qctrl-fire-opal-riken-client 1.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for qctrl-fire-opal-riken-client 1.3.0
File Size Uploaded
qctrl_fire_opal_riken_client-1.3.0.tar.gz 93.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for qctrl-fire-opal-riken-client 1.3.0
File Interpreter ABI Platform
qctrl_fire_opal_riken_client-1.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 198.4 kB

Release files / qctrl_fire_opal_riken_client-1.3.0.tar.gz

Download URL qctrl_fire_opal_riken_client-1.3.0.tar.gz
Size 93.7 kB
Tags Source
SHA-256 checksum
How to use checksums
78cb09df7cdbce510cee9ca63befe95237e758dc09c064a20bad4763c53c47fa
BLAKE2b-256 checksum
How to use checksums
a4a56d43ee3f5501ca619e71abdce1d0ebfec6f6229e7fad86a5c9ee6d6c843c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.0 CPython/3.11.16 Linux/6.17.0-1022-azure

Release files / qctrl_fire_opal_riken_client-1.3.0-py3-none-any.whl

Download URL qctrl_fire_opal_riken_client-1.3.0-py3-none-any.whl
Size 104.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
83b91fe6d340549a878e9ea1354d8c344056fd135e1d9f2213daf7e7b6ff1145
BLAKE2b-256 checksum
How to use checksums
25c83cf5d7061686a52c5c0832c444c20d64d39ab922c97d24afd7a4503186f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.0 CPython/3.11.16 Linux/6.17.0-1022-azure

Release history Release notifications | RSS feed

1.4.1

2 release files

1.4.0

2 release files

1.3.1

2 release files

This release

1.3.0 This release

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.9.1

2 release files

0.9.0

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.0

2 release files

0.6.4

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

0.0.2

2 release files

0.0.1

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page