From 2ba0f4ae27fb5fc09c5c52a47eac930c14b66f11 Mon Sep 17 00:00:00 2001 From: Masonmason Date: Thu, 24 Jul 2025 19:10:37 +0800 Subject: [PATCH] fix: Remove duplicate inference result logging to prevent terminal spam MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Comment out print() statements in InferencePipeline that duplicate GUI callback output - Prevents each inference result from appearing multiple times in terminal - Keeps logging system clean while maintaining GUI formatted display - This was causing terminal output to show each result 2-3 times due to: 1. InferencePipeline print() statements captured by StdoutCapture 2. Same results formatted and sent via terminal_output callback 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- cluster4npu_ui/core/functions/InferencePipeline.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cluster4npu_ui/core/functions/InferencePipeline.py b/cluster4npu_ui/core/functions/InferencePipeline.py index 63fec81..d697e35 100644 --- a/cluster4npu_ui/core/functions/InferencePipeline.py +++ b/cluster4npu_ui/core/functions/InferencePipeline.py @@ -244,10 +244,12 @@ class PipelineStage: # Handle tuple results like (probability, result_string) prob, result_str = result if prob is not None and result_str is not None: - print(f"[Stage {self.stage_id}] ✅ Inference result: prob={prob:.3f}, result={result_str}") + # Avoid duplicate logging - handled by GUI callback formatting + # print(f"[Stage {self.stage_id}] ✅ Inference result: prob={prob:.3f}, result={result_str}") inference_result = result elif isinstance(result, dict) and result: # Non-empty dict - print(f"[Stage {self.stage_id}] ✅ Dict result: {result}") + # Avoid duplicate logging - handled by GUI callback formatting + # print(f"[Stage {self.stage_id}] ✅ Dict result: {result}") inference_result = result else: inference_result = result