Skip to content

Commit

Permalink
CompatHelper: bump compat for "Zygote" to "0.6" for package test (#143)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: David Widmann <devmotion@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and devmotion authored Jan 6, 2021
1 parent d5a479a commit cd7f120
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion test/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ ReverseDiff = "1.4.4"
StatsBase = "0.33.2"
StatsFuns = "0.9.6"
Tracker = "0.2.12"
Zygote = "0.5.13"
Zygote = "0.5.13, 0.6"
julia = "1.3"
12 changes: 7 additions & 5 deletions test/ad/distributions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@
DistSpec(Poisson, (0.5,), 1),
DistSpec(Poisson, (0.5,), [1, 1]),

DistSpec(Skellam, (1.0, 2.0), -2),
DistSpec(Skellam, (1.0, 2.0), [-2, -2]),
DistSpec(Skellam, (1.0, 2.0), -2; broken=(:Zygote,)),
DistSpec(Skellam, (1.0, 2.0), [-2, -2]; broken=(:Zygote,)),

DistSpec(PoissonBinomial, ([0.5, 0.5],), 0),
DistSpec(PoissonBinomial, ([0.5, 0.5],), [0, 0]),
Expand Down Expand Up @@ -167,9 +167,8 @@

DistSpec(NormalCanon, (1.0, 2.0), 0.5),

DistSpec(NormalInverseGaussian, (1.0, 2.0, 1.0, 1.0), 0.5),
DistSpec(NormalInverseGaussian, (1.0, 2.0, 1.0, 1.0), 0.5; broken=(:Zygote,)),

DistSpec(Pareto, (), 1.5),
DistSpec(Pareto, (1.0,), 1.5),
DistSpec(Pareto, (1.0, 1.0), 1.5),

Expand Down Expand Up @@ -219,6 +218,9 @@
# Stackoverflow caused by SpecialFunctions.besselix
DistSpec(VonMises, (1.0,), 1.0),
DistSpec(VonMises, (1, 1), 1),

# Only some Zygote tests are broken and therefore this can not be checked
DistSpec(Pareto, (), 1.5; broken=(:Zygote,)),
]

# Tests that have a `broken` field can be executed but, according to FiniteDifferences,
Expand Down Expand Up @@ -394,7 +396,7 @@

# Skellam only fails in these tests with ReverseDiff
# Ref: https://github.com/TuringLang/DistributionsAD.jl/issues/126
filldist_broken = d.f(d.θ...) isa Skellam ? (:ReverseDiff,) : d.broken
filldist_broken = d.f(d.θ...) isa Skellam ? (d.broken..., :ReverseDiff) : d.broken
arraydist_broken = d.broken

# Create `filldist` distribution
Expand Down

0 comments on commit cd7f120

Please sign in to comment.