Coverage for /opt/conda/envs/apienv/lib/python3.10/site-packages/daiquiri/core/hardware/bliss/tomodetector.py: 0%
12 statements
« prev ^ index » next coverage.py v7.6.5, created at 2024-11-15 02:12 +0000
« prev ^ index » next coverage.py v7.6.5, created at 2024-11-15 02:12 +0000
1#!/usr/bin/env python
2# -*- coding: utf-8 -*-
3from daiquiri.core.hardware.abstract.tomodetector import (
4 TomoDetector as AbstractTomoDetector,
5)
6from daiquiri.core.hardware.abstract import HardwareProperty
7from daiquiri.core.hardware.bliss.object import BlissObject
8from daiquiri.core.hardware.bliss.object import ObjectRefProperty
9from daiquiri.core.hardware.bliss.object import EnumProperty
10from tomo.controllers.tomo_detector import TomoDetectorState
11from tomo.controllers.tomo_detector import TomoDetectorPixelSizeMode
13import logging
15logger = logging.getLogger(__name__)
18class TomoDetector(BlissObject, AbstractTomoDetector):
19 PROPERTY_MAP = {
20 "state": EnumProperty("state", enum_type=TomoDetectorState),
21 "detector": ObjectRefProperty("detector", compose=True),
22 "actual_size": HardwareProperty("actual_size"),
23 "camera_pixel_size": HardwareProperty("camera_pixel_size"),
24 "optic": ObjectRefProperty("optic", compose=True),
25 "sample_pixel_size_mode": EnumProperty(
26 "sample_pixel_size_mode", enum_type=TomoDetectorPixelSizeMode
27 ),
28 "user_sample_pixel_size": HardwareProperty("user_sample_pixel_size"),
29 "sample_pixel_size": HardwareProperty("sample_pixel_size"),
30 "source_distance": HardwareProperty("source_distance"),
31 "field_of_view": HardwareProperty("field_of_view"),
32 "acq_mode": HardwareProperty("acq_mode"),
33 }
36Default = TomoDetector