Metadata-Version: 2.4
Name: hivqe_qiskit_function_utils
Version: 0.2.1
Summary: Client-side utilities for use with Qunova Computing's HI-VQE Qiskit Function.
Author-email: Rowan Pellow-Jarman <pellow.r@qunovacomputing.com>
License-Expression: MIT
Project-URL: Homepage, https://github.com/qunovacomputing/hivqe_qiskit_function_utils
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Requires-Dist: qiskit-ibm-catalog
Requires-Dist: cryptography
Provides-Extra: dev
Requires-Dist: pytest; extra == "dev"

# HI-VQE Qiskit Function Utilities

This package is intended to provide some utilities to help users of
[Qunova's HI-VQE Qiskit
Function](https://quantum.cloud.ibm.com/functions?id=qunova-hivqe-chemistry).

## Current Features
### Helps licensed users submit their license token to the function with encryption.
The below example shows how this package can be used to wrap the
HI-VQE Qiskit Function retrieved from the Qiskit IBM Catalog to
properly submit your token:
```python
import math
from qiskit_ibm_catalog import QiskitFunctionsCatalog
from hivqe_qiskit_function_utils import FunctionWrapper


catalog = QiskitFunctionsCatalog(token="your_qiskit_functions_catalog_token", channel="ibm_quantum_platform", instance="your_ibm_instance")


molecule_geometry = f"""
O 0 0 0;
H {-0.957*math.sin(math.radians(104.5)/2.0)} {0.957*math.cos(math.radians(104.5)/2.0)} 0;
H {0.957*math.sin(math.radians(104.5)/2.0)} {0.957*math.cos(math.radians(104.5)/2.0)} 0
"""

hivqe = FunctionWrapper(token="your_hivqe_license_token", function=catalog.load("qunova/hivqe-chemistry"))
job = hivqe.run(
    geometry=molecule_geometry,
    backend_name="ibm_torino",
    max_states=10000,
    max_expansion_states=1000,
    hivqe_options={"ansatz": "epa", "max_iter": 10},
)
result = job.result()
logs = job.logs()
```
