Skip to content

Commit 98aadfd

Browse files
authored
Time series clean up (#6240)
1 parent 13dfeb2 commit 98aadfd

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

pymc/distributions/timeseries.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ class GaussianRandomWalk(PredefinedRandomWalk):
267267
sigma > 0, innovation standard deviation.
268268
init_dist : Distribution
269269
Unnamed univariate distribution of the initial value. Unnamed refers to distributions
270-
created with the ``.dist()`` API.
270+
created with the ``.dist()`` API.
271271
272272
.. warning:: init_dist will be cloned, rendering them independent of the ones passed as input.
273273
@@ -547,7 +547,7 @@ def dist(
547547
f"Init dist must be a distribution created via the `.dist()` API, "
548548
f"got {type(init_dist)}"
549549
)
550-
check_dist_not_registered(init_dist)
550+
check_dist_not_registered(init_dist)
551551
if init_dist.owner.op.ndim_supp > 1:
552552
raise ValueError(
553553
"Init distribution must have a scalar or vector support dimension, ",
@@ -617,7 +617,7 @@ def rv_op(cls, rhos, sigma, init_dist, steps, ar_order, constant_term, size=None
617617
init_dist_size = batch_size
618618
init_dist = change_dist_size(init_dist, init_dist_size)
619619

620-
# Create OpFromGraph representing random draws form AR process
620+
# Create OpFromGraph representing random draws from AR process
621621
# Variables with underscore suffix are dummy inputs into the OpFromGraph
622622
init_ = init_dist.type()
623623
rhos_ = rhos.type()

pymc/tests/distributions/test_timeseries.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -693,10 +693,10 @@ def test_moment(self, size, expected):
693693

694694
def test_init_deprecated_arg(self):
695695
with pytest.warns(FutureWarning, match="init parameter is now called init_dist"):
696-
pm.AR.dist(rho=[1, 2, 3], init=Normal.dist(), shape=(10,))
696+
AR.dist(rho=[1, 2, 3], init=Normal.dist(), shape=(10,))
697697

698698
def test_change_dist_size(self):
699-
base_dist = pm.AR.dist(rho=[0.5, 0.5], init_dist=pm.Normal.dist(size=(2,)), shape=(3, 10))
699+
base_dist = AR.dist(rho=[0.5, 0.5], init_dist=pm.Normal.dist(size=(2,)), shape=(3, 10))
700700

701701
new_dist = change_dist_size(base_dist, (4,))
702702
assert new_dist.eval().shape == (4, 10)
@@ -819,7 +819,7 @@ def test_moment(self, size, expected):
819819
assert_moment_is_expected(model, expected, check_finite_logp=True)
820820

821821
def test_change_dist_size(self):
822-
base_dist = pm.GARCH11.dist(
822+
base_dist = GARCH11.dist(
823823
omega=1.25, alpha_1=0.5, beta_1=0.45, initial_vol=1.0, shape=(3, 10)
824824
)
825825

0 commit comments

Comments
 (0)