qt3uw / qt3-utils

Data Acquisition for Confocal Microscope and Spin Control Experiments
https://sites.google.com/uw.edu/qt3-lab/projects
BSD 3-Clause "New" or "Revised" License
3 stars 6 forks source link

Remove checks for "stage_controller" in piezoscanner.py #113

Open gadamc opened 1 year ago

gadamc commented 1 year ago

In the CounterAndScanner object defined in https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py there are multiple lines where we check for the self.stage_controller (to essentially not be None). However, this object cannot be instantiated without a stage_controller passed in. Thus, these checks are pointless and should be removed.

https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py#L42 https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py#L60 https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py#L95 https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py#L122 https://github.com/qt3uw/qt3-utils/blob/main/src/qt3utils/datagenerators/piezoscanner.py#L164-L169