Skip to content

Commit

Permalink
resolve domain
Browse files Browse the repository at this point in the history
  • Loading branch information
xukai92 committed Apr 23, 2019
1 parent 6b0f3ef commit 74a7da2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/distributions/gumbel.jl
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ BatchGumbelBernoulli(p; τ=FT(0.2)) = BatchGumbelBernoulli(p, τ)
Sample from Gumbel-Bernoulli distributions.
"""
function rand(gb::BatchGumbelBernoulli{T}) where {T}
_T = isa(gb.p, AutoGrad.Result) ? typeof(value(gb)) : T
_T = isa(gb.p, AutoGrad.Result) ? typeof(Knet.value(gb)) : T

# TODO: re-implement this `rand` using the same procedure for `BatchGumbelBernoulliLogit`
FT = eltype(gb.p)
Expand Down

0 comments on commit 74a7da2

Please sign in to comment.