bella-companion 0.0.42__tar.gz → 0.0.43__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of bella-companion might be problematic. Click here for more details.
- {bella_companion-0.0.42 → bella_companion-0.0.43}/PKG-INFO +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/epi_skyline_results.py +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/shap.py +13 -7
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/fbd_no_traits_results.py +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/PKG-INFO +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/pyproject.toml +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/README.md +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/cli.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/GLM.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/MLP.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/Nonparametric.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/case_data.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/change_dates.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/msa.fasta +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/osi.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/closedborders_7e_nt.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/dist_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/flight_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/flight_pop_x_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/osi_x_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/osi_y_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/pop_x_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/pop_y_7e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/sharedborders_7e_nt.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/changetimes_all_7e.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/changetimes_flights_4e.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/flight_pop_x_4e_ls.tsv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/run_beast.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/beast_config.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/change_times.csv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/traits.csv +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/trees.nwk +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/results.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/run_beast.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/summarize_logs.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/GLM.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/MLP.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/Nonparametric.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/GLM.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/MLP.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/Nonparametric.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/GLM.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/MLP.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/Nonparametric.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/GLM.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/MLP.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/Nonparametric.xml +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/features.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/epi_multitype_results.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/pdp.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/fbd_2traits_results.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/scenarios.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/utils.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_data.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_figures.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/metrics.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/run_beast.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/common.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/epi_multitype.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/epi_skyline.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/fbd_2traits.py +1 -1
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/fbd_no_traits.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/scenario.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/summarize_logs.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/__init__.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/beast.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/explain.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/slurm.py +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/SOURCES.txt +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/dependency_links.txt +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/entry_points.txt +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/requires.txt +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/top_level.txt +0 -0
- {bella_companion-0.0.42 → bella_companion-0.0.43}/setup.cfg +0 -0
|
@@ -14,7 +14,7 @@ from bella_companion.simulations.scenarios.epi_skyline import REPRODUCTION_NUMBE
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
def plot_epi_skyline_results():
|
|
17
|
-
output_dir = Path(os.environ["BELLA_FIGURES_DIR"]) / "epi-skyline
|
|
17
|
+
output_dir = Path(os.environ["BELLA_FIGURES_DIR"]) / "epi-skyline"
|
|
18
18
|
os.makedirs(output_dir, exist_ok=True)
|
|
19
19
|
|
|
20
20
|
for i, reproduction_number in enumerate(REPRODUCTION_NUMBERS, start=1):
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
from functools import partial
|
|
2
2
|
from itertools import product
|
|
3
3
|
from pathlib import Path
|
|
4
|
+
from typing import Callable
|
|
4
5
|
|
|
5
6
|
import matplotlib.pyplot as plt
|
|
6
7
|
import numpy as np
|
|
@@ -43,13 +44,18 @@ def plot_shap_features_importance(
|
|
|
43
44
|
) # shape: (n_runs, n_features)
|
|
44
45
|
features_importances /= features_importances.sum(axis=1, keepdims=True)
|
|
45
46
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
47
|
+
def _plot_violins(group_check: Callable[[Feature], bool]):
|
|
48
|
+
for i, (feature_name, feature) in enumerate(features.items()):
|
|
49
|
+
if group_check(feature):
|
|
50
|
+
sns.violinplot(
|
|
51
|
+
y=features_importances[:, i],
|
|
52
|
+
x=[feature_name] * len(features_importances),
|
|
53
|
+
cut=0,
|
|
54
|
+
color="#E74C3C" if feature.is_relevant else "gray",
|
|
55
|
+
)
|
|
56
|
+
|
|
57
|
+
_plot_violins(lambda f: not f.is_binary)
|
|
58
|
+
_plot_violins(lambda f: f.is_binary)
|
|
53
59
|
plt.xlabel("Feature") # pyright: ignore
|
|
54
60
|
plt.ylabel("Importance") # pyright: ignore
|
|
55
61
|
plt.savefig(output_file) # pyright: ignore
|
|
@@ -14,7 +14,7 @@ from bella_companion.simulations.scenarios.fbd_no_traits import RATES
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
def plot_fbd_no_traits_results():
|
|
17
|
-
output_dir = Path(os.environ["BELLA_FIGURES_DIR"]) / "fbd-no-traits
|
|
17
|
+
output_dir = Path(os.environ["BELLA_FIGURES_DIR"]) / "fbd-no-traits"
|
|
18
18
|
os.makedirs(output_dir, exist_ok=True)
|
|
19
19
|
|
|
20
20
|
for i, rates in enumerate(RATES, start=1):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/GLM.xml
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/MLP.xml
RENAMED
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/case_data.tsv
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/change_dates.tsv
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/beast_config.xml
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/change_times.csv
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/traits.csv
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/trees.nwk
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/summarize_logs.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/pdp.py
RENAMED
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/scenarios.py
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/utils.py
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_data.py
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_figures.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/__init__.py
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/common.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -89,9 +89,9 @@ SCENARIO = Scenario(
|
|
|
89
89
|
features={
|
|
90
90
|
f"{rate}Rate": {
|
|
91
91
|
"timePredictor": Feature(is_binary=False, is_relevant=True),
|
|
92
|
-
"randomPredictor": Feature(is_binary=False, is_relevant=False),
|
|
93
92
|
"trait1Predictor": Feature(is_binary=True, is_relevant=True),
|
|
94
93
|
"trait2Predictor": Feature(is_binary=True, is_relevant=False),
|
|
94
|
+
"randomPredictor": Feature(is_binary=False, is_relevant=False),
|
|
95
95
|
}
|
|
96
96
|
for rate in RATES
|
|
97
97
|
},
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/scenario.py
RENAMED
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/summarize_logs.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|