From d9c322f9d70159a7cd82d9ed76ed5306f243b8e8 Mon Sep 17 00:00:00 2001 From: y30041989 Date: Wed, 11 Oct 2023 16:11:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E5=86=97=E4=BD=99=E4=BB=A3?= =?UTF-8?q?=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../tb_plugin/ci_scripts/install_env.sh | 17 ----------------- .../tb_plugin/fe/src/components/ModuleView.tsx | 1 - .../tb_plugin/fe/src/components/Overview.tsx | 1 - .../torch_tb_profiler/profiler/event_parser.py | 2 -- .../torch_tb_profiler/profiler/node.py | 2 -- 5 files changed, 23 deletions(-) diff --git a/plugins/tensorboard-plugins/tb_plugin/ci_scripts/install_env.sh b/plugins/tensorboard-plugins/tb_plugin/ci_scripts/install_env.sh index 11f588a03..04406ae6e 100644 --- a/plugins/tensorboard-plugins/tb_plugin/ci_scripts/install_env.sh +++ b/plugins/tensorboard-plugins/tb_plugin/ci_scripts/install_env.sh @@ -2,23 +2,6 @@ set -ex -# install cuda -#if [ "$CUDA_VERSION" = "cu101" ]; then -# wget https://developer.download.nvidia.com/compute/cuda/10.1/Prod/local_installers/cuda_10.1.243_418.87.00_linux.run -# sudo sh cuda_10.1.243_418.87.00_linux.run -#elif [ "$CUDA_VERSION" = "cu102" ]; then -# wget https://developer.download.nvidia.com/compute/cuda/10.2/Prod/local_installers/cuda_10.2.89_440.33.01_linux.run -# sudo sh cuda_10.2.89_440.33.01_linux.run -#elif [ "$CUDA_VERSION" = "cu111" ]; then -# wget https://developer.download.nvidia.com/compute/cuda/11.1.0/local_installers/cuda_11.1.0_455.23.05_linux.run -# sudo sh cuda_11.1.0_455.23.05_linux.run -#elif [ "$CUDA_VERSION" = "cu112" ]; then -# wget https://developer.download.nvidia.com/compute/cuda/11.2.0/local_installers/cuda_11.2.0_460.27.04_linux.run -# sudo sh cuda_11.2.0_460.27.04_linux.run -#fi - - - # install pytorch pip install numpy tensorboard typing-extensions pillow pytest if [ "$PYTORCH_VERSION" = "nightly" ]; then diff --git a/plugins/tensorboard-plugins/tb_plugin/fe/src/components/ModuleView.tsx b/plugins/tensorboard-plugins/tb_plugin/fe/src/components/ModuleView.tsx index e28c29f3f..38e5118c9 100644 --- a/plugins/tensorboard-plugins/tb_plugin/fe/src/components/ModuleView.tsx +++ b/plugins/tensorboard-plugins/tb_plugin/fe/src/components/ModuleView.tsx @@ -251,7 +251,6 @@ export const ModuleView: React.FC = (props) => { height={flameHeight} width={cardWidth} onChange={(node: any) => { - console.log(`"${node.name}" focused`) }} /> )} diff --git a/plugins/tensorboard-plugins/tb_plugin/fe/src/components/Overview.tsx b/plugins/tensorboard-plugins/tb_plugin/fe/src/components/Overview.tsx index c9d16bf95..afa36801a 100644 --- a/plugins/tensorboard-plugins/tb_plugin/fe/src/components/Overview.tsx +++ b/plugins/tensorboard-plugins/tb_plugin/fe/src/components/Overview.tsx @@ -93,7 +93,6 @@ export const Overview: React.FC = (props) => { setSteps(resp.steps) setRecommendations(resp.recommendations) setGpuMetrics(resp.gpu_metrics) - console.log(resp.gpu_metrics) }) }, [run, worker, span]) diff --git a/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/event_parser.py b/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/event_parser.py index 6df381ae4..213d80025 100644 --- a/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/event_parser.py +++ b/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/event_parser.py @@ -206,8 +206,6 @@ class NodeParserMixin: class StepParser: def __init__(self): # we could not use [[]] * len here since they all point to same memory - # https://stackoverflow.com/questions/12791501/python-initializing-a-list-of-lists - # https://stackoverflow.com/questions/240178/list-of-lists-changes-reflected-across-sublists-unexpectedly self.role_ranges: List[List[Tuple[int, int]]] = [[] for _ in range(ProfileRole.Total - 1)] self.steps: List[Tuple[int, int]] = [] self.steps_names: List[str] = [] diff --git a/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/node.py b/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/node.py index 027188398..54dc5d093 100644 --- a/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/node.py +++ b/plugins/tensorboard-plugins/tb_plugin/torch_tb_profiler/profiler/node.py @@ -73,8 +73,6 @@ class HostNode(BaseNode): class OperatorNode(HostNode): # Don't use [] as default parameters - # https://stackoverflow.com/questions/1132941/least-astonishment-and-the-mutable-default-argument?page=1&tab=votes#tab-top - # https://web.archive.org/web/20200221224620/http://effbot.org/zone/default-values.htm def __init__(self, children=None, runtimes=None, input_shape: Optional[List[List[int]]] = None, input_type: Optional[List[str]] = None, callstack: Optional[str] = None, self_host_duration: int = 0, self_device_duration: int = 0, **kwargs): -- Gitee