pulsatrix 1.1.0
Loading...
Searching...
No Matches
attribution_bar_chart.hpp
Go to the documentation of this file.
1
5#pragma once
6
9
10namespace pulsatrix {
11
26public:
38 static void Draw(const char* title, const Attribution& attr, int top_k = 10, float shared_max_abs = -1.0f);
39
41 static void Draw(const char* title, const AttributionDocument& doc, int top_k = 10, float shared_max_abs = -1.0f);
42};
43
44} // namespace pulsatrix
First-class explanation result type – values, method, and metadata together.
Draws a horizontal bar chart of an Attribution's top-k features (hc_information_visualization....
Definition attribution_bar_chart.hpp:25
static void Draw(const char *title, const Attribution &attr, int top_k=10, float shared_max_abs=-1.0f)
static void Draw(const char *title, const AttributionDocument &doc, int top_k=10, float shared_max_abs=-1.0f)
Draws a pulsatrix.attribution.v1 document the same way.
Versioned JSON documents (pulsatrix.<kind>.v1) that every renderer reads.
Definition acquisition_functions.hpp:16
TopKResult top_k(const Tensor &input, int64_t k, bool largest=true)
Selects the k largest (or smallest) entries of every row along the last dimension.
pulsatrix.attribution.v1: an Attribution's values, shape, method and metadata.
Definition document.hpp:58
An explanation result: the raw attribution values, the method that produced them, and any relevant me...
Definition attribution.hpp:23