diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 81dd2233..82472980 100755 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -27,10 +27,10 @@ repos: rev: v0.1.0 hooks: - id: ruff -- repo: https://github.com/numpy/numpydoc - rev: v1.6.0 - hooks: - - id: numpydoc-validation +# - repo: https://github.com/numpy/numpydoc +# rev: v1.6.0 +# hooks: +# - id: numpydoc-validation ##### # Secrets - repo: https://github.com/Yelp/detect-secrets diff --git a/model/poetry.lock b/model/poetry.lock index 164d0410..ee420f7b 100644 --- a/model/poetry.lock +++ b/model/poetry.lock @@ -2008,25 +2008,6 @@ docs = ["myst-parser", "pydata-sphinx-theme", "sphinx"] test = ["argcomplete (>=3.0.3)", "mypy (>=1.7.0)", "pre-commit", "pytest (>=7.0,<8.1)", "pytest-mock", "pytest-mypy-testing"] [[package]] -<<<<<<< HEAD -name = "urllib3" -version = "2.2.1" -description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "main" -optional = false -python-versions = ">=3.8" -files = [ - {file = "urllib3-2.2.1-py3-none-any.whl", hash = "sha256:450b20ec296a467077128bff42b73080516e71b56ff59a60a02bef2232c4fa9d"}, - {file = "urllib3-2.2.1.tar.gz", hash = "sha256:d0570876c61ab9e520d776c38acbbb5b05a776d3f9ff98a5c8fd5162a444cf19"}, -] - -[package.extras] -brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)"] -h2 = ["h2 (>=4,<5)"] -socks = ["pysocks (>=1.5.6,!=1.5.7,<2.0)"] -zstd = ["zstandard (>=0.18.0)"] - -======= name = "typing-extensions" version = "4.10.0" description = "Backported and Experimental Type Hints for Python 3.8+" @@ -2037,7 +2018,6 @@ files = [ {file = "typing_extensions-4.10.0.tar.gz", hash = "sha256:b0abd7c89e8fb96f98db18d86106ff1d90ab692004eb746cf6eda2682f91b3cb"}, ] ->>>>>>> main [[package]] name = "wcwidth" version = "0.2.13" @@ -2053,8 +2033,4 @@ files = [ [metadata] lock-version = "2.0" python-versions = "^3.10" -<<<<<<< HEAD -content-hash = "545a0d130b100754ba5b80eeb4097f4f106aa29e27b65b6d1c852e46d14efb40" -======= content-hash = "95b84b3a910f41ea2f5d2206cc15c687f74e5a4b49c35393ffd8ec694782ff8b" ->>>>>>> main diff --git a/model/src/pyrenew/latent/hospitaladmissions.py b/model/src/pyrenew/latent/hospitaladmissions.py index 7184836f..47310a98 100644 --- a/model/src/pyrenew/latent/hospitaladmissions.py +++ b/model/src/pyrenew/latent/hospitaladmissions.py @@ -63,7 +63,9 @@ class InfectHospRate(RandomVariable): def __init__( self, - dist: Optional[dist.Distribution] = dist.LogNormal(jnp.log(0.05), 0.05), + dist: Optional[dist.Distribution] = dist.LogNormal( + jnp.log(0.05), 0.05 + ), varname: Optional[str] = "IHR", ) -> None: """ diff --git a/model/src/pyrenew/latent/i0.py b/model/src/pyrenew/latent/i0.py index 3e751de2..e93fe09f 100644 --- a/model/src/pyrenew/latent/i0.py +++ b/model/src/pyrenew/latent/i0.py @@ -1,8 +1,8 @@ import numpyro as npro import numpyro.distributions as dist from pyrenew.metaclass import RandomVariable +from tpying import Any, Optional -from tpying import Optional, Any class Infections0(RandomVariable): """Initial infections helper class. diff --git a/model/src/pyrenew/latent/infections.py b/model/src/pyrenew/latent/infections.py index f5bc2458..a9d0543e 100644 --- a/model/src/pyrenew/latent/infections.py +++ b/model/src/pyrenew/latent/infections.py @@ -19,13 +19,13 @@ Attributes ---------- infections : ArrayLike or None - The estimated latent infections. Defaults to None. + The estimated latent infections. Defaults to None. """ class Infections(RandomVariable): """Latent infections - + Methods ------- sample(Rt, I0, gen_int, **kwargs) @@ -35,7 +35,7 @@ def __init__( self, infections_mean_varname: str = "latent_infections", ) -> None: - """Default constructor for Infections class. + """Default constructor for Infections class. Parameters ---------- @@ -53,7 +53,7 @@ def __init__( @staticmethod def validate() -> None: - """ + """ Notes ----- TODO: Complete this method.