Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update sampling.jl #559

Closed
wants to merge 1 commit into from
Closed

Conversation

githubtomtom
Copy link

enable make_alias_table!() for all float types. It would be useful to enable e.g. AliasTable() in Distributions.jl to create object with element type other than Float64.

enable `make_alias_table!()` for all float types. It would be useful to enable e.g. `AliasTable()` in `Distributions.jl` to create object with element type other than `Float64`.
githubtomtom added a commit to githubtomtom/Distributions.jl that referenced this pull request Feb 24, 2020
enable `rand()` from non-Float64 mixtures, e.g. `MixtureModel{Univariate,Continuous,Normal,Float32}`, now only `Float64` element type is supported.
a related [pull request](JuliaStats/StatsBase.jl#559) is made in `StatsBase. make_alias_table!()`.
@codecov
Copy link

codecov bot commented Feb 24, 2020

Codecov Report

Merging #559 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #559      +/-   ##
==========================================
+ Coverage   90.57%   90.58%   +<.01%     
==========================================
  Files          21       21              
  Lines        2239     2240       +1     
==========================================
+ Hits         2028     2029       +1     
  Misses        211      211
Impacted Files Coverage Δ
src/sampling.jl 92.16% <100%> (+0.02%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3762c78...55d47a6. Read the comment docs.

@githubtomtom
Copy link
Author

a related pull request is made in Distributions.jl

@st--
Copy link

st-- commented Oct 9, 2021

Ping! is there anything holding back merging this PR?

@devmotion
Copy link
Member

This should be fixed more generally, not only for AbstractFloat but e.g. also for integer-valued weights. I'll close this since it is a less general duplicate of #499 which contains some additional discussion as well.

@devmotion devmotion closed this Oct 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants