From 3b942e2e93f1da0c6ffc4e9f4e361a1df8d63fdf Mon Sep 17 00:00:00 2001 From: amitjans <amitjans@ethz.ch> Date: Mon, 31 May 2021 18:22:25 +0200 Subject: [PATCH] Change function name --- main.py | 4 ++-- tools.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index 336d6bf..15ed4ca 100644 --- a/main.py +++ b/main.py @@ -7,7 +7,7 @@ import numpy as np import influxdb import settings from tools import Memory, MovingAverage, to_redis, ion_positions, dark_ions, ion_linearity -from tools import detect_ion_cloud, read_factor, correct_gradient +from tools import detect_ion_cloud, read_factor, compensate_gradient from tools import TrapState, max_ion_intensity, detect_wrong_isotopes, load_image, ion_roundness conn = redis.Redis('localhost', decode_responses=True) @@ -49,7 +49,7 @@ while True: coord, max_spot_size = ion_positions(image) if len(coord) > 0: roundness = ion_roundness(image, coord[0][:2]) - new_img = correct_gradient(image) + new_img = compensate_gradient(image) max_int, num_pix = max_ion_intensity(image, coord) coord = detect_wrong_isotopes(image, coord, max_int) LINEARITY = ion_linearity(coord) diff --git a/tools.py b/tools.py index aea3ca8..963e793 100644 --- a/tools.py +++ b/tools.py @@ -291,7 +291,7 @@ def ion_linearity(points): return linearity -def correct_gradient(image): +def compensate_gradient(image): """ Measure the intensity gradient of the ions along the x axis and correct it. Ignore any basckground intensity gradient. -- GitLab