Operation of the Dectris Eiger4M Detector
This page contains documentation for the operation of the Dectris Eiger4M detector. It includes steps for activating the zmq listener, initializing and arming the detector, troubleshooting, and additional resources for handling images and using AGAVE.
Note
Note that this documentation is intended for use with the Dectris Eiger4M detector only.
Steps to Activate ZMQ Listener
Clone the reborn repository:
git clone https://gitlab.com/kirianlab/reborn.git
Switch to develop branch:
git checkout develop
Navigate to the correct directory:
cd /home/Public/Dectris/reborn/developer/rkirian/projects/cxls/dectris/fromzach/DEigerStream
Activate reborn environment:
source activate reborn
Note that this will activate the reborn conda environment.
Run DEigerStream.py: This will start the zmq listener, and display menu options for the detector.
python DEigerStream.py -i 10.139.1.5 -f junk.log
Usually best to isolate this window in a separate terminal window.
The -i flag specifies the IP address of the detector.
The -f flag specifies the name of the log file.
If desired, to exit the ZMQ listener, press Ctrl+C.
Initializing and Arming
Next, initialize and arm the detector. This will allow you to control the detector using the zmq listener.
Source setup.sh to use simplified commands like initialize, arm, disarm, etc.:
source setup.sh initialize
Note
Note that this will initialize the detector, and return true.
Set parameters and enable desired outputs using functions from setup.sh:
Choose from the options below:
enable_monitor enable_stream enable_filewriter
nimages num frame_time num count_time num nimages_per_file num
nimages sets the number of images collected in a series.
frame_time sets the frame time (time between readouts or inverse of collection rate).
count_time sets the exposure time.
nimages_per_file sets the number of images per file.
enable_monitor enables the monitor output.
enable_stream enables the stream output.
enable_filewriter enables the filewriter output.
Replace num argument with the desired number, for each function.
Able to check the options set using the following functions:
get_nimages get_frame_time get_count_time
Control the detector:
arm disarm trigger
Downloading and Overwrite Images
Navigate to the desired directory to store images:
cd /home/labuser/Public/Dectris/test/temp_data
Note
Note that this will download all images listed on http://10.139.1.5/data/.
Source the adapted setup script called adam_setup.sh and call the download function to start downloading images from http://10.139.1.5/data/:
First,
cd ~/Public
Then,
source Eiger_Setup.sh download_images_from_IP
Viewing HDF5 Images Through Reborn
Navigate to the recent downloaded images directory:
cd ~/Public/Dectris/test/temp_data
Export the Python path:
export PYTHONPATH=/home/labuser/Public/Dectris/reborn/developer/rkirian/projects/cxls/dectris/fromzach/DEigerStream:$PYTHONPATH
Run test_h5_reading.py or any other Python file:
python test_h5_reading.py
Troubleshooting
If encountering module errors, check the modules available in reborn:
conda list
Check and make sure that the reborn conda environment is activated:
conda env list
If a module is not installed, install using:
conda install module_name
Replace module_name with the desired module
Filtering Images
Using filter_nimages: This function will filter the downloaded images based on the number of images in the series.
$ cd ~/Public $ source Eiger_Setup.sh
To show all downloaded images, run the following command:
$ filter_nimages
Example output:
Found file: series_1_data_000001.h5 Found file: series_1_data_000002.h5
Using filter_master_nimages: This will show all of the master files from using the detector.
To show all master files, run the following command:
$ filter_master_nimages
Example output:
Found file: series_1_master.h5
ALBULA Image Viewer
To view images using the ALBULA image viewer, navigate to the directory containing the images, and run the following command:
$ cd ~/Public $ source Eiger_Setup.sh
$ albula_launch
This function in Eiger_Setup.sh will launch the ALBULA image viewer, and display the images in the temp_data directory.
Note that this function will only work if the temp_data directory contains images.
There is also an option to choose between master files and individual data files.
ADXV Image Viewer
To view images using the ADXV image viewer, navigate to the directory containing the images, and run the following command:
$ cd ~/Public $ source Eiger_Setup.sh
$ adxv_launch
Through the interactive GUI window, you can select the desired image to view.
Additional Resources
Please refer to AGAVE for additional information and troubleshooting.