Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds more examples #80

Merged
merged 2 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,10 @@
<img src="https://github.com/oqc-community/rasqal/blob/develop/logo.png#gh-light-mode-only" align="right" width="160px">
<img src="https://github.com/oqc-community/rasqal/blob/develop/logo_mono.png#gh-dark-mode-only" align="right" width="160px"/>

Rasqal is a quantum-classical hybrid runtime which runs QIR in a fully dynamic fashion, building up quantum circuits on the fly and executing them against a provided quantum backend.
It uses symbolic execution and heavily deferred execution to perform code transformations, optimizations and lowering to power the circuit synthesis.
Rasqal is a quantum-classical solver runtime that takes heavy inspiration from static analysis tools and SAT solvers to power optimization, transformation and circuit splice/weaving.
Its internal structures and concepts are also evolving towards a more high-level abstract representation of hybrid algorithms, so automated tools can process them better and potentially use such models to help uninitiatied developers get an intuitive understanding of quantum computing.

Some of the key things this approach enables:

1. Unrestricted QIR and LLVM instructions fully interwoven. You can throw whatever form of IR you want at it and it'll process all classical bits locally (or lower them).
2. Enabling hybrid algorithms to be run on machines and tools with only a gate-level API available. This includes QASM API's if you use its simulation framework.
3. Lots of optimization potential when passed large amounts of classical context that a quantum algorithm uses to accentuate its own execution.

We also have a [full feature list and quick intro to its concepts](https://github.com/oqc-community/rasqal/blob/develop/docs/features_and_concepts.md) as well as a [draft paper](https://github.com/oqc-community/rasqal/blob/develop/docs/papers/Rasqal%20Draft%20v3.pdf) that covers its internals in excruciating detail.
The details about its various ideas and components can be found in the [papers](https://github.com/oqc-community/rasqal/tree/develop/docs/papers) folder, while a quick introduction of them and current capabilities can be found [here](https://github.com/oqc-community/rasqal/blob/develop/docs/features_and_concepts.md).

If you have any features or ideas you'd like to see implemented feel free to raise a [feature request](https://github.com/oqc-community/Rasqal/issues/new?assignees=&labels=enhancement&projects=&template=feature_request.md&title=)!

Expand Down
17 changes: 10 additions & 7 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
## Examples

All dependencies to run the examples are installed into the Rasqal venv if you are building normally.
If you can't run the full build, use `./bulid.ps1 -t "initialize-examples"` to install a Rasqal versio from pypi as a replacement.
**Running examples without building Rasqal:** Install [poetry](https://python-poetry.org/) and do `poetry install` in `rasqal/examples` or pip install the dependencies listed in the .toml file.

All files can be run directly.
If you've already built Rasqal via its build script its venv will have all the dependencies necessary so re-use that.

**Examples.py** holds examples of how to use Rasqals Python APIs to run QIR.
Note: all our examples are built using the old Q# compiler as Rasqal can exploit its fully interwoven classical LLVM instructions.

**Sandbox.py** runs the sandbox Q# project in `qsharp/src`.
Modify the project as you need and then run the Python file to see how Rasqal reacts.
Currently restricted to adaptive profile QIR.
**Examples.py** holds runnable examples


runnable examples of many of Rasqals internal test projects showing how you set up and run things, including backend and argument definition. Shows the Q# that the QIR was generated from for each example, along with tertiary information.
Source for most examples can be found in `src/tests/qsharp` and can be modified from there and re-built.

**Sandbox.py** runs the sandbox Q# project in `qsharp/src`. This uses the new Q# compiler so instruction set is limited.
Loading
Loading