diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/README.md b/plugins/tensorboard-plugins/tb_graph_ascend/README.md index 3c92c12c2453da71aad14988719d63c326f5d354..737292598ecfdf0fb39d676ce3352fb4b246076e 100644 --- a/plugins/tensorboard-plugins/tb_graph_ascend/README.md +++ b/plugins/tensorboard-plugins/tb_graph_ascend/README.md @@ -121,7 +121,10 @@  ### 3.6 手动选择节点匹配 可通过浏览器界面,通过鼠标选择两个待匹配的灰色节点进行匹配。当前暂不支持真实数据模式。 -点击匹配后会将两个节点的子节点按照Module名称依次匹配,取消匹配后会将子节点的匹配关系清除。 +如果选中"操作选中节点及其子节点": +点击匹配后会将两个节点及其子节点按照Module名称依次匹配,取消匹配后会将子节点的匹配关系清除。 +否则: +点击匹配后只会将两个节点进行匹配,取消匹配后会将节点的匹配关系清除 注意:匹配结束之后,需要点击保存才能持久化到源文件里面  @@ -140,6 +143,10 @@ #### 4.1.1 免责声明 本工具为基于 TensorBoard 底座开发的插件,使用本插件需要基于 TensorBoard 运行,请自行关注 TensorBoard 相关安全配置和安全风险。 + +打开本工具时,本工具会对logdir目录下的vis文件以及其父目录进行安全检查,如果存在安全风险,本工具会展示如下提示信息,询问用户是否继续执行,用户选择继续执行后,可以操作未通过安全检查的文件和目录,用户需要自行承担操作风险。如果用户选择不继续执行,则用户只能操作通过安全检查的文件。 + + #### 4.1.2 TensorBoard版本说明 满足[相关依赖](#1-相关依赖)中要求的 TensorBoard 版本皆可正常使用本插件功能,但为 TensorBoard 本身安全风险考虑,建议使用最新版本 TensorBoard 。 #### 4.1.3 远程查看数据 diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/safe_warning.png b/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/safe_warning.png new file mode 100644 index 0000000000000000000000000000000000000000..15b14eab1fd7a5710cc540e1126c346f5291fb8a Binary files /dev/null and b/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/safe_warning.png differ diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/vis_match_info.png b/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/vis_match_info.png index 71e7d74991303036f02529c47dee545022647379..5785c81a2f308a4fb87db1c8528262e3b1821932 100644 Binary files a/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/vis_match_info.png and b/plugins/tensorboard-plugins/tb_graph_ascend/doc/images/vis_match_info.png differ diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/fe/package-lock.json b/plugins/tensorboard-plugins/tb_graph_ascend/fe/package-lock.json index 15f1931fe9b6ac4de59e7abf2ef953aac12ab9ed..bf84218031fe0e5fc1de5fd7f2ea4d1ffebda948 100644 --- a/plugins/tensorboard-plugins/tb_graph_ascend/fe/package-lock.json +++ b/plugins/tensorboard-plugins/tb_graph_ascend/fe/package-lock.json @@ -29,7 +29,9 @@ "@polymer/polymer": "^3.5.1", "@types/lodash": "^4.17.1", "@vaadin/button": "24.6.5", + "@vaadin/checkbox": "24.6.5", "@vaadin/combo-box": "24.6.5", + "@vaadin/confirm-dialog": "24.6.5", "@vaadin/context-menu": "24.6.5", "@vaadin/details": "24.6.5", "@vaadin/grid": "24.6.5", @@ -1217,14 +1219,14 @@ } }, "node_modules/@vaadin/a11y-base": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/a11y-base/-/a11y-base-24.6.7.tgz", - "integrity": "sha512-CJYYTWPBEEaVt4AvBE8RzEn3hqUZbGUGLzqs6NGBFTw0c5cfkqoO2ZMkKhz5Z52QF+2mCXpEtyg6s+t0h171Qg==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/a11y-base/-/a11y-base-24.6.11.tgz", + "integrity": "sha512-yBZ0QGPngbItIJQx3FRIa9IXDW2Ftf6SFFPGhbdAZafJPBlFi6FElP9cVtL3qjJlI5KKBp/UXEcC8ehPK207gw==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", "@polymer/polymer": "^3.0.0", - "@vaadin/component-base": "~24.6.7", + "@vaadin/component-base": "~24.6.11", "lit": "^3.0.0" } }, @@ -1245,19 +1247,19 @@ } }, "node_modules/@vaadin/checkbox": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/checkbox/-/checkbox-24.6.7.tgz", - "integrity": "sha512-/Vl5codokNdN5ku1l/iAkdjUmYTUZGKyAleHjM7V3ZFpwkK2IoWN4HrbWyhPuf1gL3T85bKMLSPuYoOX/ymrFw==", + "version": "24.6.5", + "resolved": "https://registry.npmmirror.com/@vaadin/checkbox/-/checkbox-24.6.5.tgz", + "integrity": "sha512-XYhiEr9PMnonyMot7y8PIK/9GlNNCxupFg7ZFsrGvsDpfD5fCfpsnv+c3kUwVN6yFze3NVQEXOyp/UGoZNoNmQ==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", "@polymer/polymer": "^3.0.0", - "@vaadin/a11y-base": "~24.6.7", - "@vaadin/component-base": "~24.6.7", - "@vaadin/field-base": "~24.6.7", - "@vaadin/vaadin-lumo-styles": "~24.6.7", - "@vaadin/vaadin-material-styles": "~24.6.7", - "@vaadin/vaadin-themable-mixin": "~24.6.7", + "@vaadin/a11y-base": "~24.6.5", + "@vaadin/component-base": "~24.6.5", + "@vaadin/field-base": "~24.6.5", + "@vaadin/vaadin-lumo-styles": "~24.6.5", + "@vaadin/vaadin-material-styles": "~24.6.5", + "@vaadin/vaadin-themable-mixin": "~24.6.5", "lit": "^3.0.0" } }, @@ -1283,9 +1285,9 @@ } }, "node_modules/@vaadin/component-base": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/component-base/-/component-base-24.6.7.tgz", - "integrity": "sha512-LcZQZEwouPDHBoXfXRREb1mRScsPSPeKTUZdgrXh180Piy57VzpNzslIMrdfVFSye9lLMs2/g2o8HCUDgnY/OQ==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/component-base/-/component-base-24.6.11.tgz", + "integrity": "sha512-7jR6vcJeCBgY2CNbAPLOcUTsxYspqdkA0slUGk3GwfgsRDD5FLkzqQDSM5+yE6O2+4Wah2Tk+kG/GsKGtlUlwg==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", @@ -1295,6 +1297,24 @@ "lit": "^3.0.0" } }, + "node_modules/@vaadin/confirm-dialog": { + "version": "24.6.5", + "resolved": "https://registry.npmmirror.com/@vaadin/confirm-dialog/-/confirm-dialog-24.6.5.tgz", + "integrity": "sha512-YkEFCj4psD/+K50fpqoJIUYRvdyzoRfWdC3ZDaDcliWND7m50cNZBxj1psZ+iOP32MVK+4Ke16fFbEY0tKoyWg==", + "license": "Apache-2.0", + "dependencies": { + "@open-wc/dedupe-mixin": "^1.3.0", + "@polymer/polymer": "^3.0.0", + "@vaadin/button": "~24.6.5", + "@vaadin/component-base": "~24.6.5", + "@vaadin/dialog": "~24.6.5", + "@vaadin/overlay": "~24.6.5", + "@vaadin/vaadin-lumo-styles": "~24.6.5", + "@vaadin/vaadin-material-styles": "~24.6.5", + "@vaadin/vaadin-themable-mixin": "~24.6.5", + "lit": "^3.0.0" + } + }, "node_modules/@vaadin/context-menu": { "version": "24.6.5", "resolved": "https://registry.npmmirror.com/@vaadin/context-menu/-/context-menu-24.6.5.tgz", @@ -1332,16 +1352,33 @@ "lit": "^3.0.0" } }, + "node_modules/@vaadin/dialog": { + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/dialog/-/dialog-24.6.11.tgz", + "integrity": "sha512-EWMkf8yH6sFEG4e9zTpPW20sL8vTz5TpBvJmD4rUUqvxEphHCUI+uO0N05/XFa2k7xZS6q8G38hc1BcCYr5Syw==", + "license": "Apache-2.0", + "dependencies": { + "@open-wc/dedupe-mixin": "^1.3.0", + "@polymer/polymer": "^3.0.0", + "@vaadin/component-base": "~24.6.11", + "@vaadin/lit-renderer": "~24.6.11", + "@vaadin/overlay": "~24.6.11", + "@vaadin/vaadin-lumo-styles": "~24.6.11", + "@vaadin/vaadin-material-styles": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11", + "lit": "^3.0.0" + } + }, "node_modules/@vaadin/field-base": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/field-base/-/field-base-24.6.7.tgz", - "integrity": "sha512-5MXpAQGZA15/hRdnZrJK5q5Mv8rgOraSyBpC/gjRJ1W1IQ5DrCcb3ltvPATguv0K3vpJwunXGXrGqm/+SGEk0w==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/field-base/-/field-base-24.6.11.tgz", + "integrity": "sha512-dRjxKzbW3xQAau1xuO8uZepVWaImS2wEyKDK9Oh+y8iiu4smYEmo9e4aqMqQN/sOHU6OSa4YtbyJZlvD1sBXrA==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", "@polymer/polymer": "^3.0.0", - "@vaadin/a11y-base": "~24.6.7", - "@vaadin/component-base": "~24.6.7", + "@vaadin/a11y-base": "~24.6.11", + "@vaadin/component-base": "~24.6.11", "lit": "^3.0.0" } }, @@ -1364,6 +1401,23 @@ "lit": "^3.0.0" } }, + "node_modules/@vaadin/grid/node_modules/@vaadin/checkbox": { + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/checkbox/-/checkbox-24.6.11.tgz", + "integrity": "sha512-Uvd6gZ3xQQrZTtCJL6f4uLbg6mXsAKjiZto7Je39yJwUHz8r5MIQr+4mLF4zc6mYVSH/Ihj/a4n9FOuTwSEuQw==", + "license": "Apache-2.0", + "dependencies": { + "@open-wc/dedupe-mixin": "^1.3.0", + "@polymer/polymer": "^3.0.0", + "@vaadin/a11y-base": "~24.6.11", + "@vaadin/component-base": "~24.6.11", + "@vaadin/field-base": "~24.6.11", + "@vaadin/vaadin-lumo-styles": "~24.6.11", + "@vaadin/vaadin-material-styles": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11", + "lit": "^3.0.0" + } + }, "node_modules/@vaadin/icon": { "version": "24.6.5", "resolved": "https://registry.npmmirror.com/@vaadin/icon/-/icon-24.6.5.tgz", @@ -1436,9 +1490,9 @@ } }, "node_modules/@vaadin/lit-renderer": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/lit-renderer/-/lit-renderer-24.6.7.tgz", - "integrity": "sha512-S9daJnGW/X+HBhOriENRYNf8hCFYABmea756onaLS0QoWLkaU3QVPKrhHjZtzNVf/15UcIeAx4C5JlIas2osFA==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/lit-renderer/-/lit-renderer-24.6.11.tgz", + "integrity": "sha512-JugFumbBQP4r28+HcbdDUVVGs5VRsqanLsifjkVrz/xb4saWv460lEYco5ES+StH+xZ2IuJZmEjEFUBSrVR/tA==", "license": "Apache-2.0", "dependencies": { "lit": "^3.0.0" @@ -1462,18 +1516,18 @@ } }, "node_modules/@vaadin/overlay": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/overlay/-/overlay-24.6.7.tgz", - "integrity": "sha512-3HZ2+Ld/ktOzFt3Ug3EoZeMqX//uKh9rsXd1d3lQl18bwVtSvG81lY7NI6tEQ2dSuniM0yy2tM+mVnV4lZq9Gw==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/overlay/-/overlay-24.6.11.tgz", + "integrity": "sha512-RrN16YWKpg2pxAu6RxlUxBbovf+1+RYRmVvUk0WKBuaA4EBli0mN1vkZbK0XEsPvC2bGHPMWWqwmUzaIXv+1bw==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", "@polymer/polymer": "^3.0.0", - "@vaadin/a11y-base": "~24.6.7", - "@vaadin/component-base": "~24.6.7", - "@vaadin/vaadin-lumo-styles": "~24.6.7", - "@vaadin/vaadin-material-styles": "~24.6.7", - "@vaadin/vaadin-themable-mixin": "~24.6.7", + "@vaadin/a11y-base": "~24.6.11", + "@vaadin/component-base": "~24.6.11", + "@vaadin/vaadin-lumo-styles": "~24.6.11", + "@vaadin/vaadin-material-styles": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11", "lit": "^3.0.0" } }, @@ -1625,46 +1679,46 @@ "license": "Apache-2.0" }, "node_modules/@vaadin/vaadin-lumo-styles": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-lumo-styles/-/vaadin-lumo-styles-24.6.7.tgz", - "integrity": "sha512-DNamU8cVxbaVn3HfRm3pN8ul95xvaem92ByVeEQwdvKaHwLI4m7AdSWKEA+13ST9TdBtCeDW6DjmtGcoEqbqiw==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-lumo-styles/-/vaadin-lumo-styles-24.6.11.tgz", + "integrity": "sha512-WRluczao8lZgImdtl66v09YjFULb1iLAhcU48aiR9igAT7h6aLeHYBvRH3AA/gBlUNwHd4xlBSl89p4HP2GGog==", "license": "Apache-2.0", "dependencies": { "@polymer/polymer": "^3.0.0", - "@vaadin/component-base": "~24.6.7", - "@vaadin/icon": "~24.6.7", - "@vaadin/vaadin-themable-mixin": "~24.6.7" + "@vaadin/component-base": "~24.6.11", + "@vaadin/icon": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11" } }, "node_modules/@vaadin/vaadin-lumo-styles/node_modules/@vaadin/icon": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/icon/-/icon-24.6.7.tgz", - "integrity": "sha512-+Cv3hLyFSXJAhnuGuPQ+hQcv9/ijZpIprJ6rqWeChvFk+bQOoPgUPx/tj67mOiTcrmV5hYt+dYs4QM7JZ//dGg==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/icon/-/icon-24.6.11.tgz", + "integrity": "sha512-CKOh+I84+GZRfMHrhtATtrw3bSW5eUArgGT4cKsOY3asoCZXUdTObPD/PqKfP4e2uAA1bgLl27kOc+W8dmibJA==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", "@polymer/polymer": "^3.0.0", - "@vaadin/component-base": "~24.6.7", - "@vaadin/vaadin-lumo-styles": "~24.6.7", - "@vaadin/vaadin-themable-mixin": "~24.6.7", + "@vaadin/component-base": "~24.6.11", + "@vaadin/vaadin-lumo-styles": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11", "lit": "^3.0.0" } }, "node_modules/@vaadin/vaadin-material-styles": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-material-styles/-/vaadin-material-styles-24.6.7.tgz", - "integrity": "sha512-7ecHOEZrFEbUz5UVSGapOt/uC7lSYV05RADCNhG16c+WsuN+oxkGIIaThMMCdBcclg5ej/BeTxZlZha8JoNO3g==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-material-styles/-/vaadin-material-styles-24.6.11.tgz", + "integrity": "sha512-tDumwlaDp/s9u++MPi64I1o2ls/drWOZf4xVPhztUjt3NwYJUeVXtwu39q0wBRIeRM7UBrs06kug2CVT72U4qQ==", "license": "Apache-2.0", "dependencies": { "@polymer/polymer": "^3.0.0", - "@vaadin/component-base": "~24.6.7", - "@vaadin/vaadin-themable-mixin": "~24.6.7" + "@vaadin/component-base": "~24.6.11", + "@vaadin/vaadin-themable-mixin": "~24.6.11" } }, "node_modules/@vaadin/vaadin-themable-mixin": { - "version": "24.6.7", - "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-themable-mixin/-/vaadin-themable-mixin-24.6.7.tgz", - "integrity": "sha512-fiVBvJWInNBq/oXeE0UAQmzadQ7UJE3ns768D1taKOwTMOxiio1UMoUXcVGwni9ASzXrd96S7F6c4aIaVqNx6A==", + "version": "24.6.11", + "resolved": "https://registry.npmmirror.com/@vaadin/vaadin-themable-mixin/-/vaadin-themable-mixin-24.6.11.tgz", + "integrity": "sha512-xCmn3X+2C7nI9LQn2OqLLkLw7VeJOCo99DlHwnxeLZpJJ/s8bjDXcIWflS+IOChzHixgEFkDSoLcNYoCR1RvYg==", "license": "Apache-2.0", "dependencies": { "@open-wc/dedupe-mixin": "^1.3.0", @@ -6569,4 +6623,4 @@ } } } -} \ No newline at end of file +} diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/fe/package.json b/plugins/tensorboard-plugins/tb_graph_ascend/fe/package.json index d5bf7321825ef2b085828176392addd974620162..fb9c1d48f45c89c57c4c9bc821db640bfc328178 100644 --- a/plugins/tensorboard-plugins/tb_graph_ascend/fe/package.json +++ b/plugins/tensorboard-plugins/tb_graph_ascend/fe/package.json @@ -50,7 +50,9 @@ "@polymer/polymer": "^3.5.1", "@types/lodash": "^4.17.1", "@vaadin/button": "24.6.5", + "@vaadin/checkbox": "24.6.5", "@vaadin/combo-box": "24.6.5", + "@vaadin/confirm-dialog": "24.6.5", "@vaadin/context-menu": "24.6.5", "@vaadin/details": "24.6.5", "@vaadin/grid": "24.6.5", @@ -73,4 +75,4 @@ "prettier": "^3.4.2", "style-loader": "^4.0.0" } -} +} \ No newline at end of file diff --git a/plugins/tensorboard-plugins/tb_graph_ascend/fe/src/graph_ascend/index.ts b/plugins/tensorboard-plugins/tb_graph_ascend/fe/src/graph_ascend/index.ts index 8a3cff935c05614cd66ba101409e7ee05823be01..a0f6a8653759ee8b210a4b4c1255f8f0fbfb5555 100644 --- a/plugins/tensorboard-plugins/tb_graph_ascend/fe/src/graph_ascend/index.ts +++ b/plugins/tensorboard-plugins/tb_graph_ascend/fe/src/graph_ascend/index.ts @@ -17,12 +17,17 @@ import { customElement, observe, property } from '@polymer/decorators'; import { html, PolymerElement } from '@polymer/polymer'; import { LegacyElementMixin } from '../polymer/legacy_element_mixin'; +import { LoadGraphFileInfoListType } from './type'; import useGraphAscend from './useGraphAscend'; import { formatBytes, safeJSONParse } from '../utils'; +import { isEmpty } from 'lodash'; import '../graph_board/index'; import '../graph_info_board/index'; import '../graph_controls_board/index'; import '../common/graph-board-layout'; +import '@vaadin/confirm-dialog' +import { Notification } from '@vaadin/notification'; + import type { SelectionType, ProgressType, GraphConfigType, GraphAllNodeType, NodeListType, UnmatchedNodeType } from './type'; @customElement('graph-ascend') @@ -82,7 +87,26 @@ class TfGraphDashboard extends LegacyElementMixin(PolymerElement) { - + + + 如果您仍坚持继续,请知悉以下风险: + 非授权路径访问可能存在信息泄露和文件内容篡改。 文件过大或格式异常,可能导致性能问题或服务中断。路径中存在软链接或权限不当,可能存在越权访问和数据篡改风险。 + 继续操作将由您自行承担相关后果。如非明确知晓风险,请取消操作并联系管理员处理。 + + + [[item.run]]/[[item.tag]]:[[item.info]] + + + +
如果您仍坚持继续,请知悉以下风险:
继续操作将由您自行承担相关后果。如非明确知晓风险,请取消操作并联系管理员处理。