pomegranate icon indicating copy to clipboard operation
pomegranate copied to clipboard

BayesianNetwork.sample not implemented (?)

Open echo66 opened this issue 6 years ago • 3 comments

Greetings!

I was trying to use the sample method as described in the API but I'm getting the following error

image

I'm using Fedora 28 and Python 3.6.

echo66 avatar Oct 13 '18 15:10 echo66

@jmschrei , is this the correct place to ask? I thought it was because, after looking into the code, it makes (at first sight) no sense for this error to exist because there is actually an implementation for the sample method.

echo66 avatar Oct 17 '18 20:10 echo66

Howdy

This is the right place to ask. While sample is implemented for every other model, there currently isn't an implementation of the sample method for Bayesian networks yet. This is because it's a bit more complicated, as one has to find the root node and begin sampling recursively from there. If you'd like to take a stab at it I'd be happy to include the contribution.

jmschrei avatar Oct 17 '18 20:10 jmschrei

+1

sashaostr avatar Dec 18 '19 12:12 sashaostr

Thank you for opening an issue. pomegranate has recently been rewritten from the ground up to use PyTorch instead of Cython (v1.0.0), and so all issues are being closed as they are likely out of date. Please re-open or start a new issue if a related issue is still present in the new codebase.

jmschrei avatar Apr 16 '23 06:04 jmschrei