This repository contains code for a hybrid quantum-classical machine learning classifier. The model is trained on the red wine quality dataset and utilizes both classical neural networks and quantum neural networks (QNNs) from Qiskit.
Ansatz:
Decision Boundary:
Navigate to the project directory:
cd ionq-ml-demo
Create a virtual environment (optional):
python3 -m venv .venv
Activate the virtual environment:
source .venv/bin/activate # On Unix or MacOS
.venv\Scripts\Activate # On Windows
Install the required packages:
pip install -r requirements.txt
-
Open the
main.ipynb
Jupyter Notebook:jupyter notebook main.ipynb
-
Run the cells in the notebook to train the model. The trained model will be saved as
model.pt
. -
To use the model in your applications, you can load it using PyTorch's
torch.load()
method.