public class SupervisedGnnExplainer extends GnnExplainer
SupervisedGraphWiseModel
.Modifier and Type | Method and Description |
---|---|
<ID> SupervisedGnnExplanation<ID> |
inferAndExplain(PgxGraph graph,
PgxVertex<ID> vertex)
Blocking version of
inferAndExplainAsync(PgxGraph, PgxVertex) . |
<ID> SupervisedGnnExplanation<ID> |
inferAndExplain(PgxGraph graph,
PgxVertex<ID> vertex,
float threshold)
Blocking version of
inferAndExplainAsync(PgxGraph, PgxVertex, float) . |
<ID> PgxFuture<SupervisedGnnExplanation<ID>> |
inferAndExplainAsync(PgxGraph graph,
PgxVertex<ID> vertex)
Performs inference on the specified vertex and generates an explanation that contains scores of how important
each property and each vertex in the computation graph is for the prediction.
|
<ID> PgxFuture<SupervisedGnnExplanation<ID>> |
inferAndExplainAsync(PgxGraph graph,
PgxVertex<ID> vertex,
float threshold)
Performs inference on the specified vertex and generates an explanation that contains scores of how important
each property and each vertex in the computation graph is for the prediction.
|
SupervisedGnnExplainer |
learningRate(double learningRate)
Set the learning rate for the explainer.
|
SupervisedGnnExplainer |
marginalize(boolean marginalize)
Set whether the explainer loss is marginalized over features.
|
SupervisedGnnExplainer |
numOptimizationSteps(int numOptimizationSteps)
Set the number of optimization steps for the explainer.
|
learningRate, marginalize, numOptimizationSteps
public <ID> SupervisedGnnExplanation<ID> inferAndExplain(PgxGraph graph, PgxVertex<ID> vertex)
inferAndExplainAsync(PgxGraph, PgxVertex)
.
Performs inference on the specified vertex and generates an explanation that contains scores of how important
each property and each vertex in the computation graph is for the prediction.graph
- the input graphvertex
- the vertexpublic <ID> SupervisedGnnExplanation<ID> inferAndExplain(PgxGraph graph, PgxVertex<ID> vertex, float threshold)
inferAndExplainAsync(PgxGraph, PgxVertex, float)
.
Performs inference on the specified vertex and generates an explanation that contains scores of how important
each property and each vertex in the computation graph is for the prediction.graph
- the input graphvertex
- the vertexthreshold
- thresholdpublic <ID> PgxFuture<SupervisedGnnExplanation<ID>> inferAndExplainAsync(PgxGraph graph, PgxVertex<ID> vertex)
graph
- the input graphvertex
- the vertexpublic <ID> PgxFuture<SupervisedGnnExplanation<ID>> inferAndExplainAsync(PgxGraph graph, PgxVertex<ID> vertex, float threshold)
graph
- the input graphvertex
- the vertexthreshold
- decision thresholdpublic SupervisedGnnExplainer learningRate(double learningRate)
learningRate
- learning ratepublic SupervisedGnnExplainer marginalize(boolean marginalize)
marginalize
- true if loss should be marginalized, false otherwisepublic SupervisedGnnExplainer numOptimizationSteps(int numOptimizationSteps)
numOptimizationSteps
- number of optimization steps