Skip to content

Commit 3d6be3e

Browse files
committed
Change formatting and remove commented out lines
1 parent 2b7ac3f commit 3d6be3e

File tree

3 files changed

+4
-15
lines changed

3 files changed

+4
-15
lines changed

pymc/distributions/timeseries.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
from pymc.distributions.continuous import Flat, Normal, get_tau_sigma
2626
from pymc.distributions.dist_math import check_parameters
2727
from pymc.distributions.shape_utils import to_tuple
28+
from pymc.util import check_dist_not_registered
2829

2930
__all__ = [
3031
"AR1",
@@ -36,8 +37,6 @@
3637
"MvStudentTRandomWalk",
3738
]
3839

39-
from pymc.util import check_dist_not_registered
40-
4140

4241
class GaussianRandomWalkRV(RandomVariable):
4342
"""

pymc/tests/test_distributions.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2635,6 +2635,7 @@ def ref_logp(value, mu, sigma, steps):
26352635
decimal=select_by_precision(float64=6, float32=1),
26362636
)
26372637

2638+
26382639
class TestBound:
26392640
"""Tests for pm.Bound distribution"""
26402641

pymc/tests/test_distributions_timeseries.py

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@
1414
import numpy as np
1515
import pytest
1616

17-
from scipy import stats
18-
1917
import pymc as pm
2018

2119
from pymc.aesaraf import floatX
@@ -26,11 +24,9 @@
2624
GARCH11,
2725
EulerMaruyama,
2826
GaussianRandomWalk,
29-
gaussianrandomwalk,
3027
)
3128
from pymc.model import Model
3229
from pymc.sampling import sample, sample_posterior_predictive
33-
from pymc.tests import test_distributions as td
3430
from pymc.tests.helpers import select_by_precision
3531
from pymc.tests.test_distributions_random import BaseTestDistributionRandom
3632

@@ -50,15 +46,8 @@ class TestGaussianRandomWalk(BaseTestDistributionRandom):
5046

5147
def check_rv_inferred_size(self):
5248
steps = self.pymc_dist_params["steps"]
53-
sizes_to_check = [
54-
None,
55-
(),
56-
1,
57-
(1,),
58-
]
49+
sizes_to_check = [None, (), 1, (1,)]
5950
sizes_expected = [(steps + 1,), (steps + 1,), (1, steps + 1), (1, steps + 1)]
60-
# sizes_to_check = [None, (), 1, (1,), 5, (4, 5), (2, 4, 2)]
61-
# sizes_expected = [(), (), (1,), (1,), (5,), (4, 5), (2, 4, 2)]
6251

6352
for size, expected in zip(sizes_to_check, sizes_expected):
6453
pymc_rv = self.pymc_dist.dist(**self.pymc_dist_params, size=size)
@@ -69,7 +58,7 @@ def check_not_implemented(self):
6958
with pytest.raises(NotImplementedError):
7059
self.pymc_rv.eval()
7160

72-
# TODO: Move this out of this test class, not related, makes more sense together with
61+
# TODO: Move this out of this test class, not related, makes more sense together with
7362
# the other logp tests
7463
def test_grw_inference(self):
7564
mu, sigma, steps = 2, 1, 10000

0 commit comments

Comments
 (0)