lop_graph_posterior_network

probly.method.lop_graph_posterior_network(input_encoder: Predictor[In, Out], latent_dim: int, num_classes: int, *, encoder_dim: int | None = None, num_flows: int = 6, class_counts: list | None = None, evidence_scale: GraphPosteriorEvidenceScale = 'latent-new', propagation_steps: int = 10, teleport_probability: float = 0.1, add_self_loops: bool = True, cache_propagation_weights: bool = True, propagation_weight_cache_size: int = 1) → LOPGraphPosteriorNetworkPredictor[In, Out][source]

Create a linear opinion pooled Graph Posterior Network (LOP-GPN) predictor.

Extends Graph Posterior Networks [SCG+21] with the linear opinion pooling approach of [DHullermeier24a]. Feature-level Dirichlet distributions are combined into mixtures using graph propagation weights.

Parameters:
  • input_encoder – Predictor applied to data.x before density modeling.

  • latent_dim – Latent dimensionality used by the normalizing flow.

  • num_classes – Number of output classes.

  • encoder_dim – Output dimensionality of input_encoder. Inferred when omitted.

  • num_flows – Number of radial flow layers per class.

  • class_counts – Optional class-count prior. If omitted, counts are inferred from data.train_mask.

  • evidence_scale – Additive log-scale for feature evidence.

  • propagation_steps – Number of APPNP propagation steps.

  • teleport_probability – APPNP teleport probability.

  • add_self_loops – Whether APPNP should add self-loops.

  • cache_propagation_weights – Whether to cache dense LOP propagation weights per edge_index tensor.

  • propagation_weight_cache_size – Maximum number of edge_index tensors to cache.

Returns:

A LOP-GPN predictor representing node predictions as Dirichlet mixtures.