@@ -536,13 +536,6 @@ def test_normal_scalar(self):
536
536
_ , pval = stats .kstest (ppc ["a" ] - trace ["mu" ], stats .norm (loc = 0 , scale = 1 ).cdf )
537
537
assert pval > 0.001
538
538
539
- # size argument not introduced to fast version [2019/08/20:rpg]
540
- with model :
541
- ppc = pm .sample_posterior_predictive (
542
- trace , size = 5 , var_names = ["a" ], return_inferencedata = False
543
- )
544
- assert ppc ["a" ].shape == (nchains * ndraws , 5 )
545
-
546
539
def test_normal_scalar_idata (self ):
547
540
nchains = 2
548
541
ndraws = 500
@@ -599,13 +592,6 @@ def test_normal_vector(self, caplog):
599
592
assert "a" in ppc
600
593
assert ppc ["a" ].shape == (12 , 2 )
601
594
602
- # size unsupported by fast_ version argument. [2019/08/19:rpg]
603
- ppc = pm .sample_posterior_predictive (
604
- trace , return_inferencedata = False , samples = 10 , var_names = ["a" ], size = 4
605
- )
606
- assert "a" in ppc
607
- assert ppc ["a" ].shape == (10 , 4 , 2 )
608
-
609
595
def test_normal_vector_idata (self , caplog ):
610
596
with pm .Model () as model :
611
597
mu = pm .Normal ("mu" , 0.0 , 1.0 )
@@ -632,9 +618,6 @@ def test_exceptions(self, caplog):
632
618
with pytest .raises (IncorrectArgumentsError ):
633
619
ppc = pm .sample_posterior_predictive (idata , samples = 10 , keep_size = True )
634
620
635
- with pytest .raises (IncorrectArgumentsError ):
636
- ppc = pm .sample_posterior_predictive (idata , size = 4 , keep_size = True )
637
-
638
621
# test wrong type argument
639
622
bad_trace = {"mu" : stats .norm .rvs (size = 1000 )}
640
623
with pytest .raises (TypeError , match = "type for `trace`" ):
@@ -658,12 +641,6 @@ def test_vector_observed(self):
658
641
assert "a" in ppc
659
642
assert ppc ["a" ].shape == (12 , 2 )
660
643
661
- ppc = pm .sample_posterior_predictive (
662
- idata , return_inferencedata = False , samples = 10 , var_names = ["a" ], size = 4
663
- )
664
- assert "a" in ppc
665
- assert ppc ["a" ].shape == (10 , 4 , 2 )
666
-
667
644
def test_sum_normal (self ):
668
645
with pm .Model () as model :
669
646
a = pm .Normal ("a" , sigma = 0.2 )
0 commit comments