Getting Started¶
Welcome to the Loom documentation! ๐
This guide will help you set up Loom on your machine and run your first tests.
Installing from GitHub¶
Install the latest release from PyPI:
Install the development version directly from GitHub:
Installing from source¶
1. Clone the repository¶
2. Install Poetry¶
Loom uses Poetry for dependency management.
We recommend installing Poetry in a dedicated virtual environment.
Run the installer:
Make Poetry available permanently by adding it to your shell config:
# For Bash
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
# For Zsh (default on Mac)
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
3. Install Loom with Poetry¶
Inside the project folder:
This will install Loom and all required dependencies inside a Poetry-managed virtual environment.
4. Optional configurations¶
-
Keep the virtual environment inside the project directory:
-
Install extra dependencies (if you plan to contribute, build docs, or use Jupyter notebooks):
5. Run the tests¶
Make sure everything works:
If all tests pass, youโre ready to use Loom! ๐
If you run into issues, check the Poetry documentation or open an issue on GitHub.
Extra. To use loom with Pennylane or CudaQ¶
If you would like to use pennylane-catalyst as the backend for loom, you have to install pennylane-catalyst separately as follows:
loom with poetry install, you can run the following command to include pennylane-catalyst into your installation process:
The same process applies for using loom with the cudaq backend.
Note that both cudaq and pennylane might not be available on all machines. We recommend installing loom + cudaq and loom + pennylane-catalyst in separate environments if the package manager raises an error.