bdext 0.1.67__tar.gz → 0.1.69__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: bdext
3
- Version: 0.1.67
3
+ Version: 0.1.69
4
4
  Summary: Estimation of BDEISS-CT parameters from phylogenetic trees.
5
5
  Home-page: https://github.com/modpath/bdeissct
6
6
  Author: Anna Zhukova
@@ -29,7 +29,7 @@ def relu_plus_one(x):
29
29
  LOSS_FUNCTIONS = {
30
30
  REPRODUCTIVE_NUMBER: "mean_absolute_percentage_error",
31
31
  INFECTION_DURATION: "mean_absolute_percentage_error",
32
- INCUBATION_PERIOD: "mean_absolute_percentage_error",
32
+ INCUBATION_PERIOD: "mae",
33
33
  UPSILON: 'mae',
34
34
  RHO: 'mean_absolute_percentage_error',
35
35
  X_C: "mean_absolute_percentage_error",
@@ -38,30 +38,30 @@ def get_write_handle(path, temp_suffix=''):
38
38
  def scale(Y, SF):
39
39
  for col in (Y.keys() if type(Y) == dict else Y.columns):
40
40
  for rate in RATE_PARAMETERS:
41
- if col.startswith(rate):
41
+ if col == rate:
42
42
  Y[col] *= SF
43
43
  for time in TIME_PARAMETERS:
44
- if col.startswith(time):
44
+ if col == time:
45
45
  Y[col] /= SF
46
46
 
47
47
 
48
48
  def scale_back(Y, SF):
49
49
  for col in (Y.keys() if type(Y) == dict else Y.columns):
50
50
  for rate in RATE_PARAMETERS:
51
- if col.startswith(rate):
51
+ if col == rate:
52
52
  Y[col] /= SF
53
53
  for time in TIME_PARAMETERS:
54
- if col.startswith(time):
54
+ if col == time:
55
55
  Y[col] *= SF
56
56
 
57
57
 
58
58
  def scale_back_array(Y, SF, columns):
59
59
  for i, col in enumerate(columns):
60
60
  for rate in RATE_PARAMETERS:
61
- if col.startswith(rate):
61
+ if col == rate:
62
62
  Y[:, i] /= SF
63
63
  for time in TIME_PARAMETERS:
64
- if col.startswith(time):
64
+ if col == time:
65
65
  Y[:, i] *= SF
66
66
 
67
67
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: bdext
3
- Version: 0.1.67
3
+ Version: 0.1.69
4
4
  Summary: Estimation of BDEISS-CT parameters from phylogenetic trees.
5
5
  Home-page: https://github.com/modpath/bdeissct
6
6
  Author: Anna Zhukova
@@ -21,7 +21,7 @@ setup(
21
21
  'Topic :: Software Development',
22
22
  'Topic :: Software Development :: Libraries :: Python Modules',
23
23
  ],
24
- version='0.1.67',
24
+ version='0.1.69',
25
25
  description='Estimation of BDEISS-CT parameters from phylogenetic trees.',
26
26
  author='Anna Zhukova',
27
27
  author_email='anna.zhukova@pasteur.fr',
File without changes
File without changes
File without changes
File without changes
File without changes