From ea7243da2964fb5731519fb71069f359a90d2c48 Mon Sep 17 00:00:00 2001 From: FEIJINTI <83849113+FEIJINTI@users.noreply.github.com> Date: Wed, 27 Jul 2022 08:20:58 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E9=98=88=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config.py | 2 +- main.py | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config.py b/config.py index 425b4c9..6e8d4e1 100644 --- a/config.py +++ b/config.py @@ -4,7 +4,7 @@ import numpy as np class Config: # 文件相关参数 - nRows, nCols, nBands, spec_size_threshold, = 256, 1024, 22, 3 + nRows, nCols, nBands, spec_size_threshold = 256, 1024, 22, 3 nRgbRows, nRgbCols, nRgbBands, rgb_size_threshold = 1024, 4096, 3, 4 # 需要设置的谱段等参数 diff --git a/main.py b/main.py index b24d49e..3f5a818 100644 --- a/main.py +++ b/main.py @@ -27,6 +27,7 @@ def main(): # 读取(开启一个管道) if len(data) < 3: threshold = int(float(data)) + Config.spec_size_threshold = threshold print("[INFO] Get threshold: ", threshold) continue else: @@ -34,6 +35,7 @@ def main(): rgb_data = os.read(fd_rgb, total_rgb) if len(rgb_data) < 3: rgb_threshold = int(float(rgb_data)) + Config.rgb_size_threshold = rgb_threshold print(rgb_threshold) continue else: