@@ -456,8 +456,6 @@ matrix_cont_dists = [
456
456
# DistSpec(:TuringInverseWishart, (dim, cov_mat), fill(cov_mat, 2)),
457
457
]
458
458
xmatrix_cont_dists = [
459
- matrix_cont_dists;
460
-
461
459
# Matrix x
462
460
filter (! isnothing, filldist_spec .(uni_cont_dists; n = (2 , 2 )));
463
461
filter (! isnothing, filldist_spec .(multi_cont_dists; disttype = :multi , n = 2 ));
@@ -469,6 +467,8 @@ xmatrix_cont_dists = [
469
467
filter (! isnothing, filldist_spec .(multi_cont_dists; disttype = :multi , n = 2 , d = 2 ));
470
468
filter (! isnothing, arraydist_spec .(uni_cont_dists; n = (2 , 2 ), d = 2 ));
471
469
filter (! isnothing, arraydist_spec .(multi_cont_dists; disttype = :multi , n = 2 , d = 2 ));
470
+
471
+ matrix_cont_dists;
472
472
]
473
473
broken_matrix_cont_dists = [
474
474
# Other
@@ -478,65 +478,67 @@ broken_matrix_cont_dists = [
478
478
DistSpec (:MatrixFDist , (dim, dim, cov_mat), cov_mat),
479
479
]
480
480
481
- test_head (s) = println (" \n " * s* " \n " )
482
- separator () = println (" \n " * " =" ^ 50 )
483
-
484
- separator ()
485
- @testset " Univariate discrete distributions" begin
486
- test_head (" Testing: Univariate discrete distributions" )
487
- for d in uni_disc_dists
488
- test_info (d. name)
489
- for testf in get_all_functions (d, false )
490
- test_ad (testf. f, testf. x)
481
+ if get_stage () != " Others"
482
+ test_head (s) = println (" \n " * s* " \n " )
483
+ separator () = println (" \n " * " =" ^ 50 )
484
+
485
+ separator ()
486
+ @testset " Univariate discrete distributions" begin
487
+ test_head (" Testing: Univariate discrete distributions" )
488
+ for d in uni_disc_dists
489
+ test_info (d. name)
490
+ for testf in get_all_functions (d, false )
491
+ test_ad (testf. f, testf. x)
492
+ end
491
493
end
492
494
end
493
- end
494
- separator ()
495
-
496
- # Note: broadcasting logpdf with univariate distributions having tracked parameters breaks
497
- # Tracker. Ref: https://github.com/FluxML/Tracker.jl/issues/65
498
- # filldist works around this so it is the recommended way for AD-friendly "broadcasting"
499
- # of logpdf with univariate distributions
500
- @testset " Univariate continuous distributions" begin
501
- test_head ( " Testing: Univariate continuous distributions " )
502
- for d in uni_cont_dists
503
- test_info (d . name )
504
- for testf in get_all_functions (d, true )
505
- test_ad (testf . f, testf . x)
495
+ separator ()
496
+
497
+ # Note: broadcasting logpdf with univariate distributions having tracked parameters breaks
498
+ # Tracker. Ref: https://github.com/FluxML/Tracker.jl/issues/65
499
+ # filldist works around this so it is the recommended way for AD-friendly "broadcasting"
500
+ # of logpdf with univariate distributions
501
+ @testset " Univariate continuous distributions" begin
502
+ test_head ( " Testing: Univariate continuous distributions" )
503
+ for d in uni_cont_dists
504
+ test_info (d . name)
505
+ for testf in get_all_functions (d, true )
506
+ test_ad (testf . f, testf . x )
507
+ end
506
508
end
507
509
end
508
- end
509
- separator ()
510
-
511
- @testset " Multivariate discrete distributions" begin
512
- test_head ( " Testing: Multivariate discrete distributions " )
513
- for d in xmulti_disc_dists
514
- test_info (d . name )
515
- for testf in get_all_functions (d, false )
516
- test_ad (testf . f, testf . x)
510
+ separator ()
511
+
512
+ @testset " Multivariate discrete distributions " begin
513
+ test_head ( " Testing: Multivariate discrete distributions" )
514
+ for d in xmulti_disc_dists
515
+ test_info (d . name)
516
+ for testf in get_all_functions (d, false )
517
+ test_ad (testf . f, testf . x )
518
+ end
517
519
end
518
520
end
519
- end
520
521
521
- separator ()
522
- @testset " Multivariate continuous distributions" begin
523
- test_head (" Testing: Multivariate continuous distributions" )
524
- for d in xmulti_cont_dists
525
- test_info (d. name)
526
- for testf in get_all_functions (d, true )
527
- test_ad (testf. f, testf. x)
522
+ separator ()
523
+ @testset " Multivariate continuous distributions" begin
524
+ test_head (" Testing: Multivariate continuous distributions" )
525
+ for d in xmulti_cont_dists
526
+ test_info (d. name)
527
+ for testf in get_all_functions (d, true )
528
+ test_ad (testf. f, testf. x)
529
+ end
528
530
end
529
531
end
530
- end
531
- separator ()
532
-
533
- @testset " Matrix-variate continuous distributions" begin
534
- test_head ( " Testing: Matrix-variate continuous distributions " )
535
- for d in xmatrix_cont_dists
536
- test_info (d . name )
537
- for testf in get_all_functions (d, true )
538
- test_ad (testf . f, testf . x)
532
+ separator ()
533
+
534
+ @testset " Matrix-variate continuous distributions " begin
535
+ test_head ( " Testing: Matrix-variate continuous distributions" )
536
+ for d in xmatrix_cont_dists
537
+ test_info (d . name)
538
+ for testf in get_all_functions (d, true )
539
+ test_ad (testf . f, testf . x )
540
+ end
539
541
end
540
542
end
543
+ separator ()
541
544
end
542
- separator ()
0 commit comments