optim: remove unuse code.
This commit is contained in:
parent
7cfc41df49
commit
5f7a4001cd
41
0003-remove-unuse-code.patch
Normal file
41
0003-remove-unuse-code.patch
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
From 74a86e20d09cbe3bba0a776f4a1c72941267f7f5 Mon Sep 17 00:00:00 2001
|
||||||
|
From: huangbin <huangbin58@huawei.com>
|
||||||
|
Date: Sat, 9 Nov 2024 16:36:16 +0800
|
||||||
|
Subject: [PATCH] remove-unuse-code
|
||||||
|
|
||||||
|
---
|
||||||
|
.../model/rca/rca_graph/prune_bidirected_graph.py | 14 --------------
|
||||||
|
1 file changed, 14 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/anteater/model/rca/rca_graph/prune_bidirected_graph.py b/anteater/model/rca/rca_graph/prune_bidirected_graph.py
|
||||||
|
index 96f3e0b..57c4c8c 100644
|
||||||
|
--- a/anteater/model/rca/rca_graph/prune_bidirected_graph.py
|
||||||
|
+++ b/anteater/model/rca/rca_graph/prune_bidirected_graph.py
|
||||||
|
@@ -12,7 +12,6 @@ import os
|
||||||
|
import json
|
||||||
|
from typing import Dict
|
||||||
|
import networkx as nx
|
||||||
|
-import matplotlib.pyplot as plt
|
||||||
|
from anteater.model.rca.rca_graph.utils import create_meta_graph
|
||||||
|
from anteater.utils.log import logger
|
||||||
|
|
||||||
|
@@ -126,16 +125,3 @@ class PrunedMetaGraph:
|
||||||
|
|
||||||
|
return self._meta_graph
|
||||||
|
|
||||||
|
-def plot_network(graph, front_end_metric=None):
|
||||||
|
- # 绘制图
|
||||||
|
- pos = nx.circular_layout(graph) # 圆形布局,起到美化作用
|
||||||
|
- color_values = []
|
||||||
|
- for node in graph.nodes():
|
||||||
|
- if node == front_end_metric:
|
||||||
|
- color_values.append(1.0)
|
||||||
|
- else:
|
||||||
|
- color_values.append(0.25)
|
||||||
|
- nx.draw(graph, pos, with_labels=True, font_weight="bold", node_color=color_values, cmap=plt.get_cmap('viridis'))
|
||||||
|
- plt.title("DiGraph")
|
||||||
|
- plt.show()
|
||||||
|
-
|
||||||
|
--
|
||||||
|
2.43.0
|
||||||
|
|
||||||
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Name: gala-anteater
|
Name: gala-anteater
|
||||||
Version: 1.2.1
|
Version: 1.2.1
|
||||||
Release: 2
|
Release: 3
|
||||||
Summary: A time-series anomaly detection platform for operating system.
|
Summary: A time-series anomaly detection platform for operating system.
|
||||||
License: MulanPSL2
|
License: MulanPSL2
|
||||||
URL: https://gitee.com/openeuler/gala-anteater
|
URL: https://gitee.com/openeuler/gala-anteater
|
||||||
@ -13,6 +13,7 @@ Requires: python3-gala-anteater = %{version}-%{release}
|
|||||||
|
|
||||||
patch0: 0001-add-new-feature-slow-node-detection.patch
|
patch0: 0001-add-new-feature-slow-node-detection.patch
|
||||||
patch1: 0002-configure-group-in-json.patch
|
patch1: 0002-configure-group-in-json.patch
|
||||||
|
patch2: 0003-remove-unuse-code.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Abnormal detection module for A-Ops project
|
Abnormal detection module for A-Ops project
|
||||||
@ -80,6 +81,9 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Nov 9 2024 huangbin <huangbin58@huawei.com> - 1.2.1-3
|
||||||
|
- remove unuse code plot network.
|
||||||
|
|
||||||
* Fri Nov 8 2024 huangbin <huangbin58@huawei.com> - 1.2.1-2
|
* Fri Nov 8 2024 huangbin <huangbin58@huawei.com> - 1.2.1-2
|
||||||
- Add new feature slow node detection.
|
- Add new feature slow node detection.
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user