Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
jrzkaminski committed Nov 1, 2023
2 parents 3f34340 + f234a9f commit 82dd79e
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
7 changes: 6 additions & 1 deletion bamt/networks/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,12 @@ def wrapper():
output[node.name] = node.choose(node_data, pvals=pvals)
return output

if progress_bar:
if predict:
seq = []
for _ in tqdm(range(n), position=0, leave=True):
result = wrapper()
seq.append(result)
elif progress_bar:
seq = Parallel(n_jobs=parall_count)(
delayed(wrapper)() for _ in tqdm(range(n), position=0, leave=True)
)
Expand Down
2 changes: 1 addition & 1 deletion docs/source/examples/add_ml_models_to_nodes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ First, lets import BAMT modules and required machine learning modules.
.. code-block:: python
import bamt.networks as networks
import bamt.Preprocessors as pp
import bamt.preprocessors as pp
import pandas as pd
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion docs/source/examples/learn_params_vis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Used imports:
.. code-block:: python
import bamt.networks as networks
import bamt.Preprocessors as pp
import bamt.preprocessors as pp
import pandas as pd
import numpy as np
Expand Down
2 changes: 1 addition & 1 deletion docs/source/examples/learn_sampling_predict.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Used imports:
.. code-block:: python
import bamt.networks as networks
import bamt.Preprocessors as pp
import bamt.preprocessors as pp
import pandas as pd
import numpy as np
Expand Down

0 comments on commit 82dd79e

Please sign in to comment.