Script execution

This commit is contained in:
gac-x04sa
2019-07-04 13:18:44 +02:00
parent d53e7d26b5
commit 3bbb7f6fb0
+5
View File
@@ -8,9 +8,14 @@ class ImageIntensity(DeviceBase, Readable):
self.setParent(image)
def read(self):
global AUTO_THRESH1_COUNT, AUTO_THRESH2_COUNT, AUTO_THRESH3_COUNT, AUTO_THRESH4_COUNT
ret = self.getParent().read()
if ret is not None:
(I_sum, area_I, thresh1_count, thresh2_count, thresh3_count, thresh4_count, I_sum_bgr, area_bgr) = ret
AUTO_THRESH1_COUNT=thresh1_count
AUTO_THRESH2_COUNT=thresh2_count
AUTO_THRESH3_COUNT=thresh3_count
AUTO_THRESH4_COUNT=thresh4_count
ret = I_sum
#if area_bgr > 0:
# ret = ret - ((I_sum_bgr / area_bgr) * area_I)