Conversation
darsnack
left a comment
There was a problem hiding this comment.
This looks good. The changes to AlphaDropout normalization tests look good. The newly added test file can just be deleted.
|
Can you delete the So far, this PR is on the correct trend, but not targeting the right set of tests to replace. Specifically, we want to replace Flux.jl/test/layers/normalisation.jl Lines 105 to 113 in 1af3f4d In other words, you should pass in a known input ( |
|
Hi @darsnack, the |
|
Also, the problem is caused by this test. @test mean(y) ≈ (q*u) + ((1-q)*α′)I will update the normalisation.jl file with this test as I cannot see it right now. I just want to know where am I going wrong in this? |
Bhavay-2001
left a comment
There was a problem hiding this comment.
The test fails here. The part that you suggested has no relation with this code I guess. Rest, please let me know what is wrong here.
|
That's because that test is testing for the wrong thing. The scaling parameters in the The code that I pointed out in the review is the actual lines of code that the original issue is referring to. |
Not |
|
Hi @darsnack @ToucheSir, I have prepared a code sample of what I have understood. Please let me know if its correct or what needs to corrected. x = ones(100)
println(x)
println("MEAN of x: ", mean(x))
m = AlphaDropout(0.4);
println(m)
y = evalwgrad(m, x)
y_ = m(x)
println(y)
println(y_)
println("MEAN of y: ", mean(y))
println("MEAN of y_: ", mean(y_))
println("SUM: ", sum(evalwgrad(m, x)))
@test mean(y) ≈ mean(y_) atol=0.1 |
|
First, We are asking have you look at An alternative test would be to look not at the mean and variance of |
Initial pull request for the Issue #1851, stating adding tests for the Alpha Dropout. This PR is based on my intial understanding of the problem. Would love to alter it further to solve the issue.
PR Checklist