For a project, I need to create synthetic categorical data containing specific dependencies between the attributes. This can be done by sampling from a pre-defined Bayesian Network. After some exploration on the internet, I found that Pomegranate
is a good package for Bayesian Networks, however - as far as I'm concerned - it seems unpossible to sample from such a pre-defined Bayesian Network. As an example, model.sample()
raises a NotImplementedError
(despite this solution says so).
Does anyone know if there exists a library which provides a good interface for the construction and sampling of/from a Bayesian network?