Skip to content

Commit

Permalink
[Probabilistic Reasoning] Fixed bug in example
Browse files Browse the repository at this point in the history
  • Loading branch information
tomsch420 committed Nov 7, 2024
1 parent 410dd80 commit cd9ac3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion examples/improving_actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ jupyter:
extension: .md
format_name: markdown
format_version: '1.3'
jupytext_version: 1.16.2
jupytext_version: 1.16.4
kernelspec:
display_name: Python 3
language: python
Expand Down Expand Up @@ -33,6 +33,7 @@ import pandas as pd
import sqlalchemy.orm

import plotly
from probabilistic_model.probabilistic_circuit.nx.probabilistic_circuit import ProbabilisticCircuit

plotly.offline.init_notebook_mode()
import plotly.graph_objects as go
Expand Down Expand Up @@ -128,6 +129,7 @@ variables = infer_variables_from_dataframe(samples, scale_continuous_types=False
min_likelihood_improvement = 0.)
model = JPT(variables, min_samples_leaf=25)
model.fit(samples)
model = ProbabilisticCircuit.from_other(model)
print(model)
```

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ gTTS~=2.5.3
dm_control
trimesh
deprecated
probabilistic_model>=6.0.0
probabilistic_model>=6.0.2
random_events>=3.1.2
sympy

0 comments on commit cd9ac3c

Please sign in to comment.