-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modify our navigational structure to handle pytorch/standalone bifurc…
…ation
- Loading branch information
1 parent
26c9ef0
commit 5ef89ea
Showing
20 changed files
with
107 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
PyTorch QCML Model Examples | ||
=========================== | ||
|
||
.. toctree:: | ||
|
||
/examples/pytorch/mnist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
QCML PyTorch MNIST | ||
================== | ||
|
||
pass |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
Stand Alone QCML Model Examples | ||
=============================== | ||
|
||
.. toctree:: | ||
|
||
/examples/stand_alone/coil20 | ||
/examples/stand_alone/wisconsin | ||
/examples/stand_alone/timeseries |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
QCML Layer | ||
========== | ||
|
||
The QCML Pytorch layer |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,15 @@ | ||
Model Selection | ||
=============== | ||
|
||
Here we will choose one of our QCML models and parameterize it for training. There are several QCML models that you can choose from and we are continuing to develop new models as well as improve existing ones. You can see which models are currently available on the sidebar. | ||
Here we will choose one of our QCML models and parameterize it for training. There are several QCML models that you can choose from and we are continuing to develop new models as well as improve existing ones. You can see which models are currently available on the sidebar. | ||
about:blank#blocked | ||
There are two categories of models. The first is a stand alone QCML model, which has at its core a single cost function that involves the quantum state. The second is a QCML PyTorch layer which has been built so that you can integrate it with classical ML deep learning layers, and so develop a hybrid quantum-classical model whose architecture fits your needs. The cost function is defined by you which is a classical cost function where QCML will be a part of the network. | ||
|
||
We're going to use the Pauli model for this example. | ||
Setting up each is a little different, so we'll cover them separately. | ||
|
||
Setting the Model Parameters | ||
---------------------------- | ||
.. toctree:: | ||
:caption: QCML Models | ||
|
||
We configure our model by a call on our ``qcml`` object, which returns the object with the model configuration. This is the same procedure for both sync and async clients. | ||
/tutorial/stand_alone/index | ||
/tutorial/pytorch/index | ||
|
||
.. code-block:: python | ||
qcml = qcml.pauli( | ||
operators=["X", "Y", "Z"], | ||
qbits=2, | ||
pauli_weight=2 | ||
) | ||
You can read more about the pauli model, the parameterization, and the available options on the :doc:`/models/pauli` page. | ||
|
||
.. note:: | ||
The operators list does have to match the dataset that you are going to be running on. This might seem redundant but it happens in lots of other machine learning models where you have to match the dimensionality of your input to the dimensions of the model - or at least do some preprocessing to get the data into the proper scale. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
PyTorch QCML | ||
============ | ||
|
||
|
||
.. toctree:: | ||
|
||
/tutorial/pytorch/models | ||
/tutorial/pytorch/train | ||
/tutorial/pytorch/inference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Inference with PyTorch | ||
====================== | ||
|
||
Inference on QCML PyTorch models will be coming mid Sept 2024! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Building a PyTorch Train Function | ||
================================= | ||
|
||
PyTorch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
PyTorch Training | ||
================ | ||
|
||
Call the train |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
Stand Alone QCML | ||
================ | ||
|
||
.. toctree:: | ||
|
||
/tutorial/stand_alone/models | ||
/tutorial/stand_alone/train | ||
/tutorial/stand_alone/inference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
Stand Alone Models | ||
================== | ||
|
||
Here we will choose one of our QCML models and parameterize it for training. There are several QCML models that you can choose from and we are continuing to develop new models as well as improve existing ones. You can see which models are currently available on the sidebar. | ||
|
||
We're going to use the Pauli model for this example. | ||
|
||
Setting the Model Parameters | ||
---------------------------- | ||
|
||
We configure our model by a call on our ``qcml`` object, which returns the object with the model configuration. This is the same procedure for both sync and async clients. | ||
|
||
.. code-block:: python | ||
qcml = qcml.pauli( | ||
operators=["X", "Y", "Z"], | ||
qbits=2, | ||
pauli_weight=2 | ||
) | ||
You can read more about the pauli model, the parameterization, and the available options on the :doc:`/models/stand_alone/pauli` page. | ||
|
||
.. note:: | ||
The operators list does have to match the dataset that you are going to be running on. This might seem redundant but it happens in lots of other machine learning models where you have to match the dimensionality of your input to the dimensions of the model - or at least do some preprocessing to get the data into the proper scale. |
File renamed without changes.