fix: remove many duplicated methods
CI / lint (push) Successful in 31s
CI / test (3.11) (push) Failing after 40s
CI / test (3.12) (push) Failing after 41s
CI / test (3.13) (push) Failing after 41s
CI / lint (pull_request) Successful in 29s
CI / test (3.11) (pull_request) Failing after 40s
CI / test (3.12) (pull_request) Failing after 41s
CI / test (3.13) (pull_request) Failing after 48s

This commit is contained in:
2026-07-31 10:24:24 +02:00
parent 7b79dd8ec5
commit 03e289c6d7
6 changed files with 16 additions and 87 deletions
-38
View File
@@ -416,16 +416,6 @@ def get_latest_image_stats():
return None
def get_latest_image_stats():
"""Get the latest image statistics including radial profile"""
global stats_receiver
if stats_receiver and stats_receiver.latest_stats:
with stats_receiver.stats_lock:
return stats_receiver.latest_stats.copy()
return None
def get_radial_profile():
"""Get just the radial profile data"""
global stats_receiver
@@ -442,31 +432,3 @@ def save_current_radial_profile(filename: str = None):
if stats_receiver:
return stats_receiver.save_radial_profile_to_file(filename)
return None
# # Auto-start when daq.py is imported/run
# if __name__ == "__main__":
# # If running daq.py directly
# start_image_stats_receiver()
#
# try:
# # Your existing daq.py code continues here
# print("DAQ system running with image statistics monitoring...")
#
# # Keep the program running
# while True:
# time.sleep(1)
#
# # Optional: Access latest stats in your main code
# latest = get_latest_image_stats()
# if latest and latest['message_count'] % 10 == 0: # Every 10th message
# print(f"Main thread sees: Mean={latest['mean']:.1f}")
#
# except KeyboardInterrupt:
# print("\nShutting down...")
# finally:
# stop_image_stats_receiver()
#
# else:
# # If daq.py is imported as a module, auto-start the receiver
# start_image_stats_receiver()