Motivation
Sioan Zohar requested GUI application which allows to select a list of sources for experiment/run.
Code location
The main class and examples of how to use it in code is in
expmon/src/SSQSourceSelector.py expmon/examples/ex_select_sources.py
See: https://github.com/lcls-psana/expmon
Setup environment
In any directory on psana node which has access to data use command
source conda_setup --reldir /reg/neh/home/dubrovin/LCLS/con-ana-sioan
- local release directory is needed until new release > ana-1.3.9 is generated.
In case If conda_setup does not work, then first use command
source /reg/g/psdm/bin/conda_setup
Run test
python /reg/neh/home/dubrovin/LCLS/con-ana-sioan/expmon/examples/ex_select_sources.py 1 ... python /reg/neh/home/dubrovin/LCLS/con-ana-sioan/expmon/examples/ex_select_sources.py 6
where additional parameter selects between different tests as follows.
1 - runs selector GUI, prints and saves selected sources in the configuration file,
you may use these sources on fly as well.
2 - gets the list of selected sources from configuration file and prints it
3 - shows how to access some other useful parameters also stored in the configuration file.
4, 5, and 6 are the same as 1, 2, and 3 but for custom file name for configuration parameters.
Selector GUI
At start of the test
python /reg/neh/home/dubrovin/LCLS/con-ana-sioan/expmon/examples/ex_select_sources.py 1
application opens a window with GUI (left plot) which helps to select instrument, experiment, and run. When instrument, experiment, and run selected the list of detector sources and epics variables shows up as a check-list (right plot). Click on check-boxes of sources and close the window.
After closing the window the list of selected sources is saved in the file with other configuration parameters printed and on terminal:
List of selected sources: 00 SxrBeamline.0:Opal1000.0 01 PhaseCavity 02 EBeam 03 LAS:FS2:VIT:FS_TGT_TIME_DIAL
References
Overview
Content Tools