---
# System prepended metadata

title: QSVM

---

# QSVM
[Hackmd Fast Tutorial](https://hackmd.io/c/tutorials-tw/%2Fs%2Fquick-start-tw)
## Paper
*    [Enhancing Quantum Support Vector Machines through Variational Kernel Training](https://arxiv.org/pdf/2305.06063.pdf)
## Dataset


## Method





## Result
### Classical
#### PCA + Linear
* MSE

|          | Training | Testing |
| -------- | -------- | -------- |
| C  | 0.00024 | 0.00020

*    Fitting Figure

| C-Training | C-Testing | 
| -------- | -------- | 
| ![](https://hackmd.io/_uploads/ryKwoaV82.png)| ![](https://hackmd.io/_uploads/Bk-uj6VU2.png) |

### IBM

# Quera
## PCA + Simple Encoding + Tuning
* Dataset
    *    output06_24.csv
* MSE

|          | Training | Testing |
| -------- | -------- | -------- |
| Q | 4e-8 | 0.00017     |
| C  | 0.00024|0.00020

* Fitting Figure



| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/SJ0bcpVLh.png) | ![](https://hackmd.io/_uploads/H1pzqTEL2.png) |

## PCA + Chain + Tuning

### Case1
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 180
    *  test : 60

* Fitting Figure



| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/HJzpeFCy6.png) | ![](https://hackmd.io/_uploads/H1AplKCka.png)
 |

### Case2
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 500
    *  test : 150

* Fitting Figure - epsilon = 0



| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/B1JLa9Cyp.png) |![](https://hackmd.io/_uploads/SJUVTqC16.png)|


* Fitting Figure - tuned

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/HytsxjCka.png) |![](https://hackmd.io/_uploads/Hkl0ljAkT.png)|
* Fitting Figure - tuned

| C-Training                                    | C-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/H1o-eoRkT.png) |![](https://hackmd.io/_uploads/rk5fesRJ6.png)|





* Q-Kernel Matrix
![](https://hackmd.io/_uploads/SJJ-1iCJa.png)

* C-Kernel Matrix
![](https://hackmd.io/_uploads/rJdgyoA16.png)

## Chain + Tuning (1009)

### Case1 - 700 data
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 700
    *  test : 210
    *  epsilon : 0.022
    *  C : 0.1
    *  $V_{ij}t=\pi$
* Fitting Figure - epsilon = 0

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/HJV7CFMZT.png)|![](https://hackmd.io/_uploads/SJAMAYMba.png)
|


* Fitting Figure - tuned

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
|  ![](https://hackmd.io/_uploads/BkrqpKM-a.png)|![](https://hackmd.io/_uploads/ByIjTYzWT.png)|
* Fitting Figure - tuned

| C-Training                                    | C-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/Hyopatz-T.png)|![](https://hackmd.io/_uploads/SklTptGW6.png)
|

* Q-Kernel Matrix
![](https://hackmd.io/_uploads/B14wRYMbp.png)

* C-Kernel Matrix
![](https://hackmd.io/_uploads/SJYI0Yfb6.png)

### Case2 - 500 data
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 700
    *  test : 210
    *  epsilon : 0.019
    *  C : 0.1
    *  $V_{ij}t=\pi$

* Fitting Figure - tuned

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/H1cm1cfW6.png)|![](https://hackmd.io/_uploads/BkI719GWa.png)
|
* Fitting Figure - tuned

| C-Training                                    | C-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
|![](https://hackmd.io/_uploads/Sy1NJczb6.png) |![](https://hackmd.io/_uploads/ByQ4JcfWp.png)
|

* Q-Kernel Matrix

![](https://hackmd.io/_uploads/Byvzk9GZT.png)

* C-Kernel Matrix
![](https://hackmd.io/_uploads/ry7fJ9fWT.png)

# Case3 - 100 data
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 100
    *  test : 30
    *  **epsilon : 0.008**
    *  C : 0.1
    *  $V_{ij}t=\pi$
* MSE

|          | Training | Testing |
| -------- | -------- | -------- |
| Q |  5.5e-5 |  0.00014  |
| C |1.2e-5 |0.00011 |
* Fitting Figure - epsilon = 0

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| | |


* Fitting Figure - tuned

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/rkH_7jmZp.png)|![](https://hackmd.io/_uploads/rJuFQjmbT.png)
|
* Fitting Figure - tuned

| C-Training                                    | C-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ![](https://hackmd.io/_uploads/rkHiQo7-T.png)|![](https://hackmd.io/_uploads/Bk6iXom-p.png)
|

* Q-Kernel Matrix
![](https://hackmd.io/_uploads/H1ORmi7-a.png)


* C-Kernel Matrix
![](https://hackmd.io/_uploads/r1-AXjXbp.png)

# Sample
*  Dataset 
    *  output08_21_BSBM.csv
    *  train : 700
    *  test : 210
    *  epsilon : 0.019
    *  C : 0.1
    *  $V_{ij}t=\pi$
* MSE

|          | Training | Testing |
| -------- | -------- | -------- |
| Q |  |    |
| C  | |
* Fitting Figure - epsilon = 0

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| | |


* Fitting Figure - tuned

| Q-Training                                    | Q-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ||
* Fitting Figure - tuned

| C-Training                                    | C-Test                                        |
| --------------------------------------------- | --------------------------------------------- |
| ||

* Q-Kernel Matrix


* C-Kernel Matrix

