MarkovRandomField.nodeset

MarkovRandomField.nodeset(names)

Set of ids for a list of names of variables in the model

Parameters:
  • lov (list of str) – List of variable names

  • names (tuple[str, ...])

Returns:

The set of ids for the list of names of the graph variables

Return type:

set

Example

import pyagrum as gum

mrf = gum.fastMRF("A--B;B--C")
mrf.nodeset(["A", "C"])
# {0, 2}

Class

MarkovRandomField