Commit 7766611a authored by Suharsh Sivakumar's avatar Suharsh Sivakumar Committed by TensorFlower Gardener
Browse files

Fix flakiness issues in c++ nn gradient tests.

Changes:
- Tolerance was too strict for L2LossGrad. Reducing tolerance to 1e-3 resolved the issue.
- Numeric gradient computation perturbation changed the value of the max value in MaxPool and MaxPoolV2 if two values were too close together (thanks Chad!). Resolved this by ensuring that the tests only compute one window on the entire input. Then I ensure that the max value of the random value is max by 1e-2, so that a perturbation can't replace it.
- Also some minor formatting fixes in nn_grad.cc
PiperOrigin-RevId: 169732110
parent 83066d45
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment