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

Add logmeanexp #81

Open
itsdfish opened this issue Feb 18, 2024 · 1 comment
Open

Add logmeanexp #81

itsdfish opened this issue Feb 18, 2024 · 1 comment

Comments

@itsdfish
Copy link
Contributor

Hi,

I noticed that R and Python have logmeanexp. I think this would be a simple, yet useful addition. I would be willing to make a PR. The basic function would be

function logmeanexp(X::AbstractArray{<:Number})
    return logsumexp(X) - log(length(X))
end

Some additional logic would be needed to handled the dims keyword.

@tpapp
Copy link
Collaborator

tpapp commented Dec 11, 2024

Is there a universally accepted definition of logmeanexp? I had to think about what it means.

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

No branches or pull requests

2 participants