-
-
Notifications
You must be signed in to change notification settings - Fork 183
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
Allow OpenCL simplex to use softmax? #2968
Comments
For ease of writing on the gpu and stability I believe the softplus will be better. Retagging @bob-carpenter who has looked into this. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
I'm in the process of writing out the deserializer for OpenCL so we can have models that run entirely on the GPU. We do not yet have a
simplex_constrain/unconstrain
function in OpenCL.I could do the stick breaking scheme on the gpu, I think it would be a weighted prefix product. That's possible for me to write but will take me a minute. The other alternative is just to use softmax. Since that's just
exp(x_i) / sum(exp(X))
that's much easier to write for the GPU.The downside of the softmax is that the cpu/gpu versions will be different, but we could just add that to the user docs so people know.
Does anyone have thoughts on this?
Current Version:
v4.7.0
The text was updated successfully, but these errors were encountered: