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.

Files changed (81) hide show
  1. {bella_companion-0.0.42 → bella_companion-0.0.43}/PKG-INFO +1 -1
  2. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/epi_skyline_results.py +1 -1
  3. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/shap.py +13 -7
  4. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/fbd_no_traits_results.py +1 -1
  5. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/PKG-INFO +1 -1
  6. {bella_companion-0.0.42 → bella_companion-0.0.43}/pyproject.toml +1 -1
  7. {bella_companion-0.0.42 → bella_companion-0.0.43}/README.md +0 -0
  8. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/__init__.py +0 -0
  9. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/cli.py +0 -0
  10. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/__init__.py +0 -0
  11. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/GLM.xml +0 -0
  12. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/MLP.xml +0 -0
  13. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/beast_configs/Nonparametric.xml +0 -0
  14. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/case_data.tsv +0 -0
  15. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/change_dates.tsv +0 -0
  16. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/msa.fasta +0 -0
  17. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/osi.tsv +0 -0
  18. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/closedborders_7e_nt.tsv +0 -0
  19. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/dist_7e_ls.tsv +0 -0
  20. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/flight_7e_ls.tsv +0 -0
  21. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/flight_pop_x_7e_ls.tsv +0 -0
  22. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/osi_x_7e_ls.tsv +0 -0
  23. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/osi_y_7e_ls.tsv +0 -0
  24. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/pop_x_7e_ls.tsv +0 -0
  25. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/pop_y_7e_ls.tsv +0 -0
  26. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/all/sharedborders_7e_nt.tsv +0 -0
  27. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/changetimes_all_7e.tsv +0 -0
  28. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/changetimes_flights_4e.tsv +0 -0
  29. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/data/predictors/flight_pop_x_4e_ls.tsv +0 -0
  30. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/eucovid/run_beast.py +0 -0
  31. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/__init__.py +0 -0
  32. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/beast_config.xml +0 -0
  33. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/change_times.csv +0 -0
  34. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/traits.csv +0 -0
  35. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/data/trees.nwk +0 -0
  36. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/results.py +0 -0
  37. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/run_beast.py +0 -0
  38. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/platyrrhine/summarize_logs.py +0 -0
  39. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/__init__.py +0 -0
  40. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/GLM.xml +0 -0
  41. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/MLP.xml +0 -0
  42. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-multitype/Nonparametric.xml +0 -0
  43. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/GLM.xml +0 -0
  44. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/MLP.xml +0 -0
  45. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/epi-skyline/Nonparametric.xml +0 -0
  46. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/GLM.xml +0 -0
  47. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/MLP.xml +0 -0
  48. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-2traits/Nonparametric.xml +0 -0
  49. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/GLM.xml +0 -0
  50. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/MLP.xml +0 -0
  51. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/beast_configs/fbd-no-traits/Nonparametric.xml +0 -0
  52. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/features.py +0 -0
  53. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/__init__.py +0 -0
  54. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/epi_multitype_results.py +0 -0
  55. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/__init__.py +0 -0
  56. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/explain/pdp.py +0 -0
  57. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/fbd_2traits_results.py +0 -0
  58. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/scenarios.py +0 -0
  59. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/figures/utils.py +0 -0
  60. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_data.py +0 -0
  61. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/generate_figures.py +0 -0
  62. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/metrics.py +0 -0
  63. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/run_beast.py +0 -0
  64. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/__init__.py +0 -0
  65. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/common.py +0 -0
  66. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/epi_multitype.py +0 -0
  67. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/epi_skyline.py +0 -0
  68. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/fbd_2traits.py +1 -1
  69. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/fbd_no_traits.py +0 -0
  70. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/scenarios/scenario.py +0 -0
  71. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/simulations/summarize_logs.py +0 -0
  72. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/__init__.py +0 -0
  73. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/beast.py +0 -0
  74. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/explain.py +0 -0
  75. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion/utils/slurm.py +0 -0
  76. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/SOURCES.txt +0 -0
  77. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/dependency_links.txt +0 -0
  78. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/entry_points.txt +0 -0
  79. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/requires.txt +0 -0
  80. {bella_companion-0.0.42 → bella_companion-0.0.43}/bella_companion.egg-info/top_level.txt +0 -0
  81. {bella_companion-0.0.42 → bella_companion-0.0.43}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bella-companion
3
- Version: 0.0.42
3
+ Version: 0.0.43
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.10
6
6
  Description-Content-Type: text/markdown
@@ -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-results"
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
- for i, (feature_name, feature) in enumerate(features.items()):
47
- sns.violinplot(
48
- y=features_importances[:, i],
49
- x=[feature_name] * len(features_importances),
50
- cut=0,
51
- color="#E74C3C" if feature.is_relevant else "gray",
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-predictions"
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):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bella-companion
3
- Version: 0.0.42
3
+ Version: 0.0.43
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.10
6
6
  Description-Content-Type: text/markdown
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "bella-companion"
3
- version = "0.0.42"
3
+ version = "0.0.43"
4
4
  description = "Add your description here"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.10"
@@ -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
  },