-
Notifications
You must be signed in to change notification settings - Fork 1
Software Setup
Among the following steps, some steps are only required for computers that actually controls the Sinara hardware. These steps are labeled as (control only).
Assumes that a Windows computer is used with Anaconda installed. ARTIQ should work on Linux (probably with significant speed gain when compiling experiments), and with other package managers (e.g., nix), but these are not tested.
Code should be stored in "C:\Users\scientist\code" (needs to be included in the PYTHONPATH
environment variable). pydux
repository is required. There should be a folder called config
in the code
folder. Required config files in pydux.lib.config
needs to be copied to config
.
The following code creates a new environment named artiq
with ARTIQ with required packages. These are copied from the ARTIQ manual (with change of the new environment name) and refer to the manual if the following commands do not work.
conda config --prepend channels https://conda.m-labs.hk/artiq-beta
conda config --append channels conda-forge
conda create -n artiq python=3.8
activate artiq
conda install artiq
To activate the environment, run
activate artiq
Install packages required by LabRAD in this environment too. cd
to "C:\Users\scientist\code\pydux", and then run
pip install -r requirements.txt
(control only) Install additional packages for controlling hardware. See the commented items in requirements.txt
for examples.
We use our fork of artiq
. The repository needs to be cloned to "C:\Users\scientist\code", and "C:\Users\scientist\code\artiq" needs to be included in PYTHONPATH
environment variable (note the extra artiq
in the path). This forked artiq
, instead of the package installed in the code3
environment, is used.
(control only) Clone artiq_exps
to "C:\Users\scientist\code". This repository contains all ARTIQ experiments. Copy all files from "C:\Users\scientist\code\artiq_exps.githooks" to "C:\Users\scientist\code\artiq_exps.git\hooks", and remove .sample
in these file names.
(control only) Make a new artiq_master
folder in "C:\Users\scientist\code", and copy device_db.py
file in this folder. The device_db.py
should be provided by M-Labs (unless we purchase boards through a different supplier). Create artiq_master.bat
with the below content, with __ip_address__
replaced by the public (physics computing services) IP address of the control computer (no quotes around the IP address).
activate artiq && artiq_master -g -r "C:\Users\scientist\code\artiq_exps" --bind=__ip_address__
(control only) Make artiq_master.py
in "C:\Users\scientist\code\config". See ARTIQ master config for instructions. A data saving folder needs to be defined in this step. Recommended location for the data folder: "C:\Users\scientist\data\ __computer_name__
_data", with __computer_name__
replaced by the computer name (all lower case, and note the dash after __computer_name__
). The data should be periodically copied to the Google Drive for backup.
Make artiq_dashboard.py
in "C:\Users\scientist\code\config". See ARTIQ dashboard config for instructions.
Optionally, create a H5_DATAFOLDER
environment variable. This environment variable should points to the parent of the data folder for a control computer ("C:\Users\scientist\data" given the above recommended location for the data folder). For other computers, likely best to set the environment variable to the data folder in the Google Drive (e.g., "M:\My Drive\data"). This step would not affect using ARTIQ in most cases, and only provides a way to load data without connecting to LabRAD on the control computers.