Grafana dashboard: dataset_result_ob
Description: 查看「选定算法」在「选定数据集」下的整体检测指标和「各个序列」的检测指标


{
  "__inputs": [
    {
      "name": "DS_TSAD_EVALUATOR",
      "label": "TSAD_Evaluator",
      "description": "",
      "type": "datasource",
      "pluginId": "influxdb",
      "pluginName": "InfluxDB"
    }
  ],
  "__elements": [],
  "__requires": [
    {
      "type": "panel",
      "id": "barchart",
      "name": "Bar chart",
      "version": ""
    },
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "8.4.5"
    },
    {
      "type": "datasource",
      "id": "influxdb",
      "name": "InfluxDB",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "stat",
      "name": "Stat",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "target": {
          "limit": 100,
          "matchAny": false,
          "tags": [],
          "type": "dashboard"
        },
        "type": "dashboard"
      }
    ]
  },
  "editable": true,
  "fiscalYearStartMonth": 0,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1655101212234,
  "links": [],
  "liveNow": false,
  "panels": [
    {
      "collapsed": false,
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "id": 9,
      "panels": [],
      "title": "Total Metric",
      "type": "row"
    },
    {
      "datasource": {
        "type": "influxdb",
        "uid": "${DS_TSAD_EVALUATOR}"
      },
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          }
        },
        "overrides": []
      },
      "gridPos": {
        "h": 7,
        "w": 24,
        "x": 0,
        "y": 1
      },
      "id": 4,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "center",
        "orientation": "vertical",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.5",
      "targets": [
        {
          "alias": "",
          "query": "SELECT mean(*) from (select ${metric:doublequote} FROM result_ts_meta WHERE \"ds_name\" = '$dataset' and \"detector_name\" = '$detector')",
          "rawQuery": true,
          "refId": "A",
          "resultFormat": "table"
        }
      ],
      "transparent": true,
      "type": "stat"
    },
    {
      "collapsed": false,
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 8
      },
      "id": 2,
      "panels": [],
      "title": "Metric by time series",
      "type": "row"
    },
    {
      "datasource": {
        "type": "influxdb",
        "uid": "${DS_TSAD_EVALUATOR}"
      },
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "hidden",
            "axisSoftMin": 0,
            "fillOpacity": 80,
            "gradientMode": "hue",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineWidth": 1,
            "scaleDistribution": {
              "type": "linear"
            }
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          }
        },
        "overrides": []
      },
      "gridPos": {
        "h": 29,
        "w": 12,
        "x": 0,
        "y": 9
      },
      "id": 6,
      "maxPerRow": 2,
      "options": {
        "barRadius": 0,
        "barWidth": 0.97,
        "groupWidth": 0.7,
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "orientation": "horizontal",
        "showValue": "auto",
        "stacking": "none",
        "text": {},
        "tooltip": {
          "mode": "single",
          "sort": "none"
        },
        "xTickLabelRotation": 0,
        "xTickLabelSpacing": 0
      },
      "pluginVersion": "8.0.6",
      "repeat": "metric",
      "repeatDirection": "h",
      "targets": [
        {
          "query": "select ts_name, $order($metric, $top) from result_ts_meta where \"ds_name\" = '$dataset' and \"detector_name\" = '$detector'  ",
          "rawQuery": true,
          "refId": "A",
          "resultFormat": "table"
        }
      ],
      "title": "$metric",
      "transparent": true,
      "type": "barchart"
    }
  ],
  "schemaVersion": 35,
  "style": "dark",
  "tags": [],
  "templating": {
    "list": [
      {
        "current": {},
        "datasource": {
          "type": "influxdb",
          "uid": "${DS_TSAD_EVALUATOR}"
        },
        "definition": "select ds_name from ( select * from result_ts_meta)",
        "hide": 0,
        "includeAll": false,
        "multi": false,
        "name": "dataset",
        "options": [],
        "query": "select ds_name from ( select * from result_ts_meta)",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "type": "query"
      },
      {
        "current": {},
        "datasource": {
          "type": "influxdb",
          "uid": "${DS_TSAD_EVALUATOR}"
        },
        "definition": "select detector_name from (select * from result_ts_meta where \"ds_name\" = '$dataset')",
        "hide": 0,
        "includeAll": false,
        "multi": false,
        "name": "detector",
        "options": [],
        "query": "select detector_name from (select * from result_ts_meta where \"ds_name\" = '$dataset')",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "type": "query"
      },
      {
        "current": {},
        "datasource": {
          "type": "influxdb",
          "uid": "${DS_TSAD_EVALUATOR}"
        },
        "definition": "show field keys from result_ts_meta",
        "hide": 0,
        "includeAll": false,
        "multi": true,
        "name": "metric",
        "options": [],
        "query": "show field keys from result_ts_meta",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "type": "query"
      },
      {
        "current": {
          "selected": true,
          "text": "30",
          "value": "30"
        },
        "hide": 0,
        "includeAll": false,
        "multi": false,
        "name": "top",
        "options": [
          {
            "selected": false,
            "text": "10",
            "value": "10"
          },
          {
            "selected": false,
            "text": "20",
            "value": "20"
          },
          {
            "selected": true,
            "text": "30",
            "value": "30"
          },
          {
            "selected": false,
            "text": "50",
            "value": "50"
          },
          {
            "selected": false,
            "text": "100",
            "value": "100"
          }
        ],
        "query": "10,20,30,50,100",
        "queryValue": "",
        "skipUrlSync": false,
        "type": "custom"
      },
      {
        "current": {
          "selected": true,
          "text": "asc",
          "value": "bottom"
        },
        "hide": 0,
        "includeAll": false,
        "multi": false,
        "name": "order",
        "options": [
          {
            "selected": true,
            "text": "asc",
            "value": "bottom"
          },
          {
            "selected": false,
            "text": "desc",
            "value": "top"
          }
        ],
        "query": "asc : bottom,  desc : top",
        "queryValue": "",
        "skipUrlSync": false,
        "type": "custom"
      }
    ]
  },
  "time": {
    "from": "now-6h",
    "to": "now"
  },
  "timepicker": {},
  "timezone": "",
  "title": "dataset_result_ob",
  "uid": "QnmP-PEnk",
  "version": 1,
  "weekStart": "",
  "gnetId": 16437,
  "description": "查看「选定算法」在「选定数据集」下的整体检测指标和「各个序列」的检测指标"
}