mirror of
https://github.com/NanjingForestryUniversity/supermachine-tobacco.git
synced 2025-11-08 14:23:55 +00:00
增加了预测但不输出
This commit is contained in:
parent
dcbc2f49eb
commit
15a465a6d1
2
main.py
2
main.py
@ -58,9 +58,11 @@ def main(only_spec=False, only_color=False):
|
|||||||
if only_spec:
|
if only_spec:
|
||||||
# 光谱识别
|
# 光谱识别
|
||||||
mask_spec = spec_detector.predict(img_data)
|
mask_spec = spec_detector.predict(img_data)
|
||||||
|
mask_rgb = rgb_detector.predict(rgb_data)
|
||||||
mask_rgb = np.zeros_like(mask_spec, dtype=np.uint8)
|
mask_rgb = np.zeros_like(mask_spec, dtype=np.uint8)
|
||||||
elif only_color:
|
elif only_color:
|
||||||
# rgb识别
|
# rgb识别
|
||||||
|
mask_spec = spec_detector.predict(img_data)
|
||||||
mask_rgb = rgb_detector.predict(rgb_data)
|
mask_rgb = rgb_detector.predict(rgb_data)
|
||||||
mask_spec = np.zeros_like(mask_rgb, dtype=np.uint8)
|
mask_spec = np.zeros_like(mask_rgb, dtype=np.uint8)
|
||||||
else:
|
else:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user