LoopyBeliefPropagation.setPeriodSize

LoopyBeliefPropagation.setPeriodSize(p)
Parameters:

p (int) – the number of iterations between two checks of the stopping criteria (and between two values of history())

Raises:

pyagrum.OutOfBounds – If p<1

Return type:

None

Example

import pyagrum as gum

bn = gum.fastBN("A->B<-C")
ie = gum.LoopyBeliefPropagation(bn)
ie.periodSize()
# 1
ie.setPeriodSize(50)
ie.periodSize()
# 50

Class

LoopyBeliefPropagation