Skip to content

Commit

Permalink
Don't Float32-result in massof for BATDistMeasure
Browse files Browse the repository at this point in the history
static(1.0) and true always promote to Float64 under log, etc.
  • Loading branch information
oschulz committed Nov 4, 2024
1 parent ac6c1ee commit 7b9255d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/measures/bat_dist_measure.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ MeasureBase.getdof(m::BATDistMeasure) = eff_totalndof(m.dist)
MeasureBase.rootmeasure(::BATDistMeasure{<:Distribution{Univariate,Continuous}}) = MeasureBase.LebesgueBase()
MeasureBase.rootmeasure(m::BATDistMeasure{<:Distribution{Multivariate,Continuous}}) = MeasureBase.LebesgueBase() ^ size(m.dist)

MeasureBase.massof(::BATDistMeasure) = static(1.0)
MeasureBase.massof(::BATDistMeasure) = 1.0f0


function DensityInterface.logdensityof(m::BATDistMeasure{<:Distribution{Univariate,Continuous}}, v::Real)
Expand Down

0 comments on commit 7b9255d

Please sign in to comment.