From 1c53682c13fe9db204089fdb203dc459e4c0200a Mon Sep 17 00:00:00 2001 From: chenchao99 Date: Thu, 18 Jun 2020 21:49:09 +0800 Subject: [PATCH] adapte the aicpu update --- mindinsight/profiler/analyser/analyser.py | 7 +++---- mindinsight/profiler/analyser/integrator.py | 5 ++--- mindinsight/profiler/common/validator/validate.py | 4 ++-- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/mindinsight/profiler/analyser/analyser.py b/mindinsight/profiler/analyser/analyser.py index deeb36f..2c1db35 100644 --- a/mindinsight/profiler/analyser/analyser.py +++ b/mindinsight/profiler/analyser/analyser.py @@ -262,9 +262,8 @@ class AicpuAnalyser(BaseAnalyser): Raises: ProfilerPathErrorException: If the profiling dir is invalid. """ - _col_names = ['serial_number', 'op_name', 'total_time', 'dispatch_time', - 'RunV2_start', 'compute_start', 'memcpy_start', 'memcpy_end', - 'RunV2_end'] + _col_names = ['serial_number', 'op_type', 'total_time', 'dispatch_time', + 'run_start', 'run_end'] _file_name_aicpu_time = 'aicpu_intermediate_{}.csv' def _load(self): @@ -306,4 +305,4 @@ class AicpuAnalyser(BaseAnalyser): list[Union[str, float]], the converted data. """ return [int(row[0]), row[1], float(row[2]), float(row[3]), int(row[4]), - int(row[5]), int(row[6]), int(row[7]), int(row[8])] + int(row[5])] diff --git a/mindinsight/profiler/analyser/integrator.py b/mindinsight/profiler/analyser/integrator.py index e29eab7..65248a2 100644 --- a/mindinsight/profiler/analyser/integrator.py +++ b/mindinsight/profiler/analyser/integrator.py @@ -33,9 +33,8 @@ class Integrator: _header_aicore_type = ['op_type', 'execution_time', 'execution_frequency', 'percent'] _header_aicore_detail = ['full_op_name', 'execution_time'] - _header_aicpu = ['serial_number', 'op_name', 'total_time', 'dispatch_time', - 'RunV2_start', 'compute_start', 'memcpy_start', - 'memcpy_end', 'RunV2_end'] + _header_aicpu = ['serial_number', 'op_type', 'total_time', 'dispatch_time', + 'run_start', 'run_end'] def __init__(self, profiling_dir, device_id): self._profiling_dir = profiling_dir diff --git a/mindinsight/profiler/common/validator/validate.py b/mindinsight/profiler/common/validator/validate.py index 24aba79..3e4d18d 100644 --- a/mindinsight/profiler/common/validator/validate.py +++ b/mindinsight/profiler/common/validator/validate.py @@ -25,8 +25,8 @@ from mindinsight.profiler.common.log import logger as log AICORE_TYPE_COL = ["op_type", "execution_time", "execution_frequency", "precent"] AICORE_DETAIL_COL = ["op_name", "op_type", "execution_time", "subgraph", "full_op_name"] -AICPU_COL = ["serial_number", "op_name", "total_time", "dispatch_time", "RunV2_start", - "compute_start", "memcpy_start", "memcpy_end", "RunV2_end"] +AICPU_COL = ["serial_number", "op_type", "total_time", "dispatch_time", "run_start", + "run_end"] MINDDATA_PIPELINE_COL = [ 'op_id', 'op_type', 'num_workers', 'output_queue_average_size', 'output_queue_length', 'output_queue_usage_rate', 'sample_interval', -- GitLab