January 29, 2025
Access cutting-edge research tools with PennyLane Labs
Keeping up to date with the latest research papers can be a struggle—not to mention tracking down the code to reproduce those new results. What if you could get access to the latest code features and implementation, while the research is happening?
Now you can! The latest release of PennyLane comes with the all-new PennyLane Labs module, which provides cutting-edge tools tailored for research.
These tools are developed by researchers, for research, across fields such as quantum chemistry, quantum compilation, and quantum machine learning. While they may be a little rough around the edges, we want to make sure the tools that power novel ideas and results at Xanadu are getting into your hands, faster. To start using these tools and PennyLane Labs, check out the Labs documentation, or keep reading to learn more about Labs and how you can get involved.
Contents
- PennyLane is driving research 🚗
- What is PennyLane Labs? 🥼
- Why use PennyLane Labs? 🧑🔬
- Using PennyLane Labs 👓
- Be Careful! 🚧
- Where to go next? 🔬
PennyLane is driving research 🚗
Fundamental quantum computing and quantum algorithm research is difficult, and quantum software is a key tool in helping to make new breakthroughs and discoveries. With PennyLane, we want to make research as easy and as accessible as possible, and today many research groups are relying on PennyLane—from Olivia Di Matteo's group at the University of British Columbia (where PennyLane is the "go-to framework for developing and testing quantum algorithms"), to Christian Gogolin and his team at Covestro, where PennyLane is a key component of quantum computing research.
Researchers can count on PennyLane because our teams work hard to keep the ecosystem stable and continuously evolving. Even internally, our research teams at Xanadu both depend on and contribute to PennyLane, leading to rapid iteration between research and software. This way, we always have dependable, cutting-edge tools for research. Check out our most recent release to see what's new!
We know that research and code go hand-in-hand, iteratively evolving side by side to get to those breakthrough results in quantum simulation, materials simulation, and more. Oftentimes, it can be hard to share or keep track of this fast-moving code, especially when the project direction changes.
While these tools develop faster than we can integrate them with PennyLane, we still want to share the latest developments with you. What then? That’s where Labs comes in, hosting documented and tested code that is actively used to obtain research results.
What is PennyLane Labs? 🥼
PennyLane Labs is an experimental module, with functionality added directly by researchers. As research projects progress, additions and removals to Labs happen quickly, according to research needs. But as with all PennyLane features, our same high standard of detailed documentation makes it straightforward to get up to speed on these new state-of-the-art functionalities, while tests ensure that our simulations are correct and our results are reliable.
So what does this all look like? The first release of PennyLane Labs gives you access to:
- Resource estimation: faster resource estimation with lower memory requirements, including the
get_resources
function for obtaining the resources from a quantum circuit in terms of a target gate set. - Dynamical Lie Algebras: tools to define Lie closures, calculate Cartan decompositions, and enable the KAK decomposition to analyze, decompose, and compress quantum circuits.
More details about these features are available in the Labs section of our release notes. Stay tuned for upcoming additions like product formulas for Hamiltonian time evolution, their incurred errors, and physical resource estimation.
Why use PennyLane Labs? 🧑🔬
- Get a sneak peek: See and use functionality and code driving the latest research results faster, as the research is happening.
- Reproduce the latest results: Access the code used in the latest Xanadu research to reproduce, generalize, or build upon recent results.
- Test Labs features: Experiment with the tools and share your feedback! The top tools will be revisited, tuned as necessary, and then moved to a more permanent module in PennyLane.
- Suggest improvements: Let us know how we can make these features more useful to you, for example through improvements such as differentiability or JIT integration.
- Collaborate with us: Contribute your own cutting-edge research code to PennyLane.
Using PennyLane Labs 👓
To use Labs, simply install PennyLane:
pip install pennylane
Or, install the development version of PL directly from GitHub to get the most up-to-date Labs module:
pip install git+https://github.com/PennyLaneAI/pennylane.git@master
Note that Labs has to be imported separately to use its functions and submodules:
import pennylane as qml from pennylane import labs
Be Careful! 🚧
Make use of PennyLane Labs at your leisure, but proceed with caution! ⚠️
The rapid pace of development used for this research software means that it might not be compatible with all of the PennyLane features that you’re used to, including differentiability as well as JAX and JIT compatibility.
PennyLane Labs moves fast! Stability and long-term feature support are not guaranteed. So don’t expect features to stick around forever; if you find a Labs feature to be useful, then be sure to let us know!
Where to go next? 🔬
Now that you’re in the know, it’s time to go-go-go and dive into PennyLane Labs! 🏊
For more details on the available features in Labs, consult the Labs documentation. Also, check out our most recent additions to Labs in the PennyLane release notes. Try them out and share your thoughts on GitHub or our discussion forum!
About the authors
Diego Guala
Diego is a quantum scientist at Xanadu. His work is focused on supporting the development of the datasets service and PennyLane features.
Isaac De Vlugt
My job is to help manage the PennyLane and Catalyst feature roadmap... and spam lots of emojis in the chat 🤠
Josh Izaac
Josh is a theoretical physicist, software tinkerer, and occasional baker. At Xanadu, he contributes to the development and growth of Xanadu’s open-source quantum software products.
Justin Pickering
Hello 👋 I'm a Product Operations Manager at Xanadu, working with the PennyLane team.