pystruct.models.EdgeFeatureGraphCRF — pystruct 0.2.4 documentation

n_states : int, default=None

Number of states for all variables. Inferred from data if not provided.

n_features : int, default=None

Number of features per node. Inferred from data if not provided.

n_edge_features : int, default=None

Number of features per edge. Inferred from data if not provided.

inference_method : string, default=”ad3”

Function to call do do inference and loss-augmented inference. Possible values are:

  • ‘max-product’ for max-product belief propagation.
  • ‘lp’ for Linear Programming relaxation using cvxopt.
  • ‘ad3’ for AD3 dual decomposition.
  • ‘qpbo’ for QPBO + alpha expansion.

class_weight : None, or array-like

Class weights. If an array-like is passed, it must have length n_classes. None means equal class weights.

symmetric_edge_features : None or list

Indices of edge features that are forced to be symmetric. Often the direction of the edge has no immediate meaning.

antisymmetric_edge_features : None or list

Indices of edge features that are forced to be anti-symmetric.