APS Bluesky 101 - Presenter’s Notes#
Note: The following content are notes for the presenter from 2021, not the training itself.
Overview#
The APS Bluesky 101 class provides a basic, yet hands-on, introduction to using the Bluesky framework.
The class should take (roughly) about 3 hours. The first hour will cover from the Welcome through the Jupyter Lab section. The remaining time will be spent on the Connect with EPICS and scan with Bluesky section.
The Linux Virtual Machine provides a complete, self-contained system with all software installed, similar to what is used for scientific measurements with an APS instrument, includes Bluesky software, EPICS client tools (both command line and GUI), IOCs for area detector and general purpose work, web browsers, graphical text editors, MongoDB database server, and Python infrastructure.
Syllabus#
Note: time spans are estimates
half-hour
Welcome
Check VMs are working
spot check (should check before class to fix problems) or follow as observer
apply software updates & patches:
cd ~/training git stash git pull bash ./patch1.sh cd ~/
check that IOC is running:
caget gp:UPTIME
in terminal
half-hour
start Jupyter lab:
blueskyStarter.sh lab
Bluesky: Brief Introduction
Open file _intro2bluesky.md with Markdown preview in Jupyter lab session
hour - interactive notebooks
hello_world.ipynb
notebookbasic-motor-scaler-scan.ipynb
notebookstart caQtDM and view motor
gp:m1
:start_caQtDM_gp
(in a new terminal tab)Connect the motor
Connect the scaler
Prepare to scan
Break
half-hour
First scan
discussion
Fix a few problems
half-hour
Scan with a different counting time : staging
Custom plan with configurable count time
Discussion
Before the class#
(required) Install the Virtual Machine on your workstation if you are permitted to install software on your computer.
If you cannot install and run the VM, you can attend the course as an observer or view the video later. A link to the video will be provided once it becomes available.
(helpful) Read the VM Overview and the EPICS hardware simulations provided.
(helpful) Have a basic understanding of running programs in Linux.
Covered here#
Not covered here#
How is Bluesky deployed at the APS? (hint: This class provides an example.)
Are there other tutorials available online? Yes!
How to use EPICS area detectors? (setup, measure, analyze from databroker)
How to support complex devices?
How does databroker store the data?
What is MongoDB?
Reference#
Links to the videos from the training sessions of 2021 August and September are publicly-available on Box.com: https://anl.box.com/s/5ovic1hhoxrek9as0idawy61z9a32n4l
Community#
Information#
More on EpicsSignal including
ophyd.Device
For more about Juypter, see the Bluesky Hello Python and Jupyter Tutorial.