-
Notifications
You must be signed in to change notification settings - Fork 35
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
Overloading the sampling functions of probability distributions #48
Comments
Hi, first of all instead of overloading Layer by modifying its source code, you could also use the convenience function As for saving the output, there are a few work-arounds:
|
Wow, I didn't expect to get an answer this quick. What a neat solution. I tried Option 1, and it seems to work well so far! Thanks! |
Hi,
I'm trying to overload some sampling functions of probability distributions according to Jankowiak(2018) http://arxiv.org/abs/1806.01851
Fortunately, Matlab already supports functions like gamrnd so what I have to do is just overloading those functions via modifying Layer.m and autonn_der.m
However, as you can see in the equation (58) of the paper, it requires to get the original output value of the overloaded function, which is represented as z in the paper. It seems like that all the functions in autonn_der.m are currently having a form of dx = function(x, dy). I don't know how to pass the output value (y) and change it to have a form of dx = function(x, y, dy)
Can you give me a hint about how I can give the output value in the backpropagation stage?
The text was updated successfully, but these errors were encountered: