pystruct.inference.
inference_lp
(unary_potentials, pairwise_potentials, edges, relaxed=False, return_energy=False, **kwargs)[source]¶Inference with buildin LP solver using cvxopt backend.
Parameters:  unary_potentials : ndarray, shape (n_nodes, n_nodes)
pairwise_potentials : ndarray, shape (n_states, n_states) or (n_states, n_states, n_edges).
edges : ndarray, shape (n_edges, 2)
relaxed : bool (default=False)
return_energy : bool (default=False)


Returns:  labels : ndarray
