Skip to content

Library for Q# implementing various qRAM proposals

License

Notifications You must be signed in to change notification settings

AadiPapp/qram

 
 

Repository files navigation

qRAM Library for Q#

Unitary Fund

This library implements a variety of different proposals for memory for quantum computers, also commonly called qRAM. Want to learn more about what qRAM is? Check out the primer on memory for quantum computers in our docs!

Motivation

There are many different proposals for qRAM in quantum computing that each have different tradeoffs, and currently come up a lot in quantum machine learning applications. We want to better understand the costs and benefits of different qRAM implementations in quantum machine learning as well as quantum computing more generally. This library will help achieve these goals by giving us a concrete way to measure the resources each approach takes; choosing to do this in Q# allows us to leverage the built-in resource estimator to quickly iterate profiling the qRAM implementations and optimizing the circuits.

Build status

Run Tests Build and publish NuGet package to GitHub packages

Code style

q# code style q# APIcode style c# APIcode style CoC

Screenshots

Example of a Bucket Brigade qRAM circuit:

Bucket Brigade qRAM

TODO: Include logo/demo screenshot etc.

Tech/framework used

Built with:

Features

What makes your project stand out?

Code Example

TODO: Add more! Fix syntax highlighting

operation QueryAndMeasureQRAM(memory : QRAM, queryAddress : Int) : Int {
        using ((addressRegister, targetRegister) = (Qubit[memory::AddressSize], Qubit[memory::DataSize])) {
            ApplyPauliFromBitString (PauliX, true, IntAsBoolArray(queryAddress, memory::AddressSize), addressRegister);
            memory::Lookup(LittleEndian(addressRegister), targetRegister);
            ResetAll(addressRegister);
            return MeasureInteger(LittleEndian(targetRegister));
        }
    }

Installation

TODO:

  • Docker
  • Binder
  • Codespaces
  • Remote development environment with VS Code
    • Dev container is in .devcontainer, see instructions for VSCode on how to launch.
  • local install

API Reference

TODO: Complete once compiler extension is finalized for scraping API docs

Tests

TODO: Describe and show how to run the tests with code examples.

How to use?

TODO: Link to user manual in docs

Contribute

Please see our contributing guidelines and our code of conduct before working on a contribution, thanks!

Credits

  • Primary developers: @glassnotes, @shikharsingh3, @crazy4pi314
  • Code review and API design assistance: @RolfHuisman, @cgranade

Anything else that seems useful

  • WIQCA talk on qRAM by @glassnotes
  • Live development of this library with @crazy4pi314 on Twitch

License

MIT © qsharp-community

About

Library for Q# implementing various qRAM proposals

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published