Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
projects:quantum:categorical [2025/04/30 09:12] – [Categorical Structure of Quantum ML] kymki | projects:quantum:categorical [2025/05/01 21:23] (current) – [Shim - a Rust library for categorical quantum computing] kymki | ||
---|---|---|---|
Line 48: | Line 48: | ||
===== Reader Guidance | ===== Reader Guidance | ||
- | This entry is a an overview of the code examples (shorter bits of demonstrative code that use the Shim library) that I have implemented. It is technical. It is assumed that this is perhaps not the first time the reader has heard of category theory. The reading will benefit greatly from basic prior knowledge of concepts like monads, functors (ofc how can we otherwise grok monads), categories. Basic knowledge of quantum computing is needed but I set the level of the text to not assume deep prior expertise. | + | This entry is a an overview of the code examples (shorter bits of demonstrative code that use the [[https:// |
What im hoping is that for someone active in category theory research, ML, or quantum computing can read this post and understand why I started writing Shim and see its value as a research tool. Please do contact me should you find this interesting and if any inaccuracies (I know quite a few in the code already) exist. Im happy to collaborate and discuss. | What im hoping is that for someone active in category theory research, ML, or quantum computing can read this post and understand why I started writing Shim and see its value as a research tool. Please do contact me should you find this interesting and if any inaccuracies (I know quite a few in the code already) exist. Im happy to collaborate and discuss. | ||
Line 55: | Line 55: | ||
===== Shim - a Rust library for categorical quantum computing ===== | ===== Shim - a Rust library for categorical quantum computing ===== | ||
- | Shim is a Rust library that provides a mathematical foundation for quantum machine learning using category theory. It aims to describe quantum computation and machine learning through categorical structures, enabling composition of quantum operations and data transformations. | + | Shim is a Rust library |
In the repo there are three larger illustrative examples that showcase its usage. This is just a highlight of some of the categorical concepts used in Shim. For a full read, clone the git repo and run the examples that come with extensive documentation. | In the repo there are three larger illustrative examples that showcase its usage. This is just a highlight of some of the categorical concepts used in Shim. For a full read, clone the git repo and run the examples that come with extensive documentation. | ||
Line 411: | Line 411: | ||
</ | </ | ||
- | The functors formalize how classical data is encoded into quantum states and how quantum measurements are decoded into predictions. This categorical structure ensures that these transformations preserve essential algebraic properties. | + | The functors formalize how classical data is encoded into quantum states and how quantum measurements are decoded into predictions. |
==== Natural Transformations for Quantum Processes ==== | ==== Natural Transformations for Quantum Processes ==== | ||
Line 560: | Line 560: | ||
</ | </ | ||
- | This verification ensures that the categorical structure is properly maintained, which is essential | + | This verification ensures that the categorical structure is properly maintained for the mathematical consistency of the quantum machine learning pipeline. |
==== Inference Pipeline and Evaluation ==== | ==== Inference Pipeline and Evaluation ==== | ||
Line 627: | Line 627: | ||
</ | </ | ||
- | This inference pipeline processes classical data through the entire quantum machine learning workflow, from data encoding to prediction, illustrating how the categorical structure enables a coherent quantum information processing workflow. | + | This inference pipeline processes classical data through the entire quantum machine learning workflow, from data encoding to prediction. |
==== End-to-End Categorical Composition ==== | ==== End-to-End Categorical Composition ==== | ||
- | The framework | + | The code further |
<code rust> | <code rust> | ||
Line 748: | Line 748: | ||
</ | </ | ||
- | This encoding strategy | + | Here, via the above encoding strategy, classical features can be systematically mapped to quantum operations, creating a well-defined interface between classical and quantum data. |
- | ==== Practical Benefits of the Categorical Approach ==== | ||
- | The implementation demonstrates several practical benefits | + | ===== 4. Conclusion and Outlook: |
- | * **Systematic Experimentation**: | + | What I wanted to demonstrate with the implementation of Shim is that that category theory |
- | * **Formal Verification**: | + | |
- | * **Compositionality**: | + | |
- | * **Abstraction**: | + | |
- | * **Scalability**: | + | |
- | + | ||
- | ===== 4. Conclusion and Outlook: The Power of Categorical Quantum ML ===== | + | |
- | What I wanted to demonstrate with the implementation of Shim is that that category theory provides a useful mathematical language for quantum computing with specific applications towards machine learning. | + | By formalizing quantum operations, data transformations, |
* **Mathematical Verification**: | * **Mathematical Verification**: |