torch_geometric.explain.metric.characterization_score
- characterization_score(pos_fidelity: Tensor, neg_fidelity: Tensor, pos_weight: float = 0.5, neg_weight: float = 0.5) Tensor[source]
返回如“GraphFramEx: Towards Systematic Evaluation of Explainability Methods for Graph Neural Networks”论文中所述的组件特征评分。
\[\textrm{charact} = \frac{w_{+} + w_{-}}{\frac{w_{+}}{\textrm{fid}_{+}} + \frac{w_{-}}{1 - \textrm{fid}_{-}}}\]- Parameters:
pos_fidelity (torch.Tensor) – 正保真度 \(\textrm{fid}_{+}\).
neg_fidelity (torch.Tensor) – 负保真度 \(\textrm{fid}_{-}\).
pos_weight (float, optional) – \(\textrm{fid}_{+}\) 的权重 \(w_{+}\)。(默认值:
0.5)neg_weight (float, optional) – \(\textrm{fid}_{-}\) 的权重 \(w_{-}\)。(默认值:
0.5)
- Return type: