BayesNet.evIn
- BayesNet.evIn(name, val1, val2)
This method is used to set an observation on a quasi-continuous variables (
pyagrum.DiscretizedVariablewith a large number of ticks) that the variable is in a given range.Notes
see also Tensor.evIn
see also BayesNet.evEq, BayesNet.evGt, BayesNet.evLt
- Parameters:
var (
int | str) – the current name or the id of the variablevalueMin (
float) – the minimum valuevalueMax (
float) – the maximum valuename (
str)val1 (
float)val2 (
float)
- Returns:
The representation of the evidence as a
pyagrum.Tensor.- Return type:
Example
import pyagrum as gum
bn = gum.fastBN("A[0:10:5]") # 5 intervals from 0 to 10
bn.evIn("A", 3, 7).tolist()
# [0.0, 1.0, 1.0, 1.0, 0.0]
Class