Skip to content

Commit 7f4726c

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent bef1a0d commit 7f4726c

21 files changed

+26
-17
lines changed

docs/source/_static/images/make_infectiousness_period.ipynb

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,7 @@
125125
],
126126
"source": [
127127
"dist_mean = 2 * 0.12 + 4 * 0.29 + 6 * 0.47 + 10 * 0.12\n",
128-
"dist_var = (\n",
129-
" 2 ** 2 * 0.12 + 4 ** 2 * 0.29 + 6 ** 2 * 0.47 + 10 ** 2 * 0.12 - dist_mean ** 2\n",
130-
")\n",
128+
"dist_var = 2**2 * 0.12 + 4**2 * 0.29 + 6**2 * 0.47 + 10**2 * 0.12 - dist_mean**2\n",
131129
"dist_std = np.sqrt(dist_var)\n",
132130
"dist_mean, dist_std"
133131
]

docs/source/_static/images/make_time_until_death.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"source": [
4242
"mean = 11.74\n",
4343
"std = 8.79\n",
44-
"var = 8.79 ** 2\n",
44+
"var = 8.79**2\n",
4545
"\n",
4646
"print(mean, std)"
4747
]

docs/source/_static/images/make_time_until_icu_recovery.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"source": [
4242
"mean = 18.8\n",
4343
"std = 12.21\n",
44-
"var = std ** 2\n",
44+
"var = std**2\n",
4545
"\n",
4646
"print(mean, std)"
4747
]

setup.cfg

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,14 @@ url = https://github.com/covid-19-impact-lab/sid
77
author = Janos Gabler, Tobias Raabe, Klara Roehrl
88
author_email = janos.gabler@gmail.com
99
license = MIT
10-
license_file = LICENSE
10+
license_files = LICENSE
1111
platforms = any
1212
classifiers =
1313
Development Status :: 3 - Alpha
1414
Intended Audience :: Science/Research
15-
License :: OSI Approved :: MIT License
1615
Operating System :: OS Independent
1716
Programming Language :: Python :: 3
1817
Programming Language :: Python :: 3 :: Only
19-
Programming Language :: Python :: 3.6
20-
Programming Language :: Python :: 3.7
21-
Programming Language :: Python :: 3.8
22-
Programming Language :: Python :: 3.9
2318
Topic :: Scientific/Engineering
2419
project_urls =
2520
Changelog = https://sid-dev.readthedocs.io/en/latest/changes.html
@@ -41,7 +36,7 @@ install_requires =
4136
python-snappy
4237
seaborn
4338
tqdm
44-
python_requires = >=3.6
39+
python_requires = >=3.10
4540
include_package_data = True
4641
package_dir =
4742
=src

src/sid/colors.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
https://github.com/covid-19-impact-lab/utilities/blob/master/utilities/colors.py.""
44
55
"""
6+
67
import numpy as np
78
import seaborn as sns
89
from matplotlib.colors import LinearSegmentedColormap

src/sid/config.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""This module contains configuration values for sid."""
2+
23
from pathlib import Path
34

45
import numpy as np

src/sid/contacts.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""This module contains everything related to contacts and matching."""
2+
23
import itertools
34
from typing import Any
45
from typing import Dict

src/sid/events.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""This module contains the code to calculate infections by events."""
2+
23
import pandas as pd
34
from sid.config import DTYPE_VIRUS_STRAIN
45
from sid.virus_strains import combine_first_factorized_infections

src/sid/initial_conditions.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
beginning of a simulation and can used to create patterns which match the real data.
55
66
"""
7+
78
import itertools
89
import math
910
from typing import Any
@@ -456,9 +457,9 @@ def _sample_factorized_virus_strains_for_infections(
456457
sampled_virus_strains = np.random.choice(
457458
virus_strain_factors, p=probabilities, size=n_infected
458459
)
459-
spread_out_virus_strains.loc[
460-
spread_out_infections[column], column
461-
] = sampled_virus_strains
460+
spread_out_virus_strains.loc[spread_out_infections[column], column] = (
461+
sampled_virus_strains
462+
)
462463

463464
return spread_out_virus_strains
464465

src/sid/matching_probabilities.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Functions to work with transition matrices for assortative matching."""
2+
23
import string
34
import warnings
45
from typing import List

0 commit comments

Comments
 (0)