Fix incorrect logging in mi_gpu_spec.py (#626)

* Move console logging to logger function to avoid circular dependency in utils module

Signed-off-by: coleramos425 <colramos@amd.com>

* Apply python formatting

Signed-off-by: coleramos425 <colramos@amd.com>

* Remove the default StreamHandler before adding the custom

 If you are not explicitly removing this default handler, it could be causing duplicate outputs.

Signed-off-by: coleramos425 <colramos@amd.com>

* Fix lingering bugs from merge conflict resolution

Signed-off-by: coleramos425 <colramos@amd.com>

* Comply to python formatting and update pre-commit hook helper

Signed-off-by: coleramos425 <colramos@amd.com>

* Removing redundant console_log call as the get_mi300_num_xcds() call, otherwise ALL Mi200 profiling runs will print this message

Signed-off-by: coleramos425 <colramos@amd.com>

---------

Signed-off-by: coleramos425 <colramos@amd.com>

[ROCm/rocprofiler-compute commit: 04f92b72a9]
This commit is contained in:
Cole Ramos
2025-03-25 17:06:37 -05:00
committed by GitHub
parent a851c977c7
commit 088fa6a4ac
31 changed files with 132 additions and 129 deletions
@@ -30,14 +30,8 @@ from collections import OrderedDict
from pathlib import Path
from utils import file_io, parser, schema
from utils.utils import (
console_debug,
console_error,
console_log,
demarcate,
is_workload_empty,
merge_counters_spatial_multiplex,
)
from utils.logger import console_debug, console_error, console_log, demarcate
from utils.utils import is_workload_empty, merge_counters_spatial_multiplex
class OmniAnalyze_Base:
@@ -25,7 +25,7 @@
from rocprof_compute_analyze.analysis_base import OmniAnalyze_Base
from utils import file_io, parser, tty
from utils.kernel_name_shortener import kernel_name_shortener
from utils.utils import console_error, demarcate
from utils.logger import console_error, demarcate
class cli_analysis(OmniAnalyze_Base):
@@ -35,7 +35,7 @@ from dash.dependencies import Input, Output, State
from rocprof_compute_analyze.analysis_base import OmniAnalyze_Base
from utils import file_io, parser
from utils.gui import build_bar_chart, build_table_chart
from utils.utils import console_debug, console_error, demarcate
from utils.logger import console_debug, console_error, demarcate
PROJECT_NAME = "rocprofiler-compute"