Skip to content

Commit

Permalink
Initialize filter and bias to prevent flakiness (#3343)
Browse files Browse the repository at this point in the history
Summary:
Another flaky test fix.
Pull Request resolved: #3343

Differential Revision: D16592248

Pulled By: jfix71

fbshipit-source-id: 39be2e9d34de3abfa4c25112dc35f9fc2a2a6043
  • Loading branch information
jfix71 authored and facebook-github-bot committed Aug 1, 2019
1 parent 3709c3b commit 77a0e4e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/unittests/QuantizationTest.cpp
Expand Up @@ -247,6 +247,8 @@ static void quantizeSimpleConvGraph(ElemKind quantizationPrecision) {
auto outTy = mod.uniqueType(ElemKind::FloatTy, {1, 4, 8, 2});
PlaceholderBindings bindings;
bindings.allocate(input);
filter->getHandle().randomize(-1.0, 1.0, mod.getPRNG());
bias->getHandle().randomize(-1.0, 1.0, mod.getPRNG());

auto *CN = F->createConv("Conv", input, filter, bias, outTy, {2, 2}, {1, 1},
{0, 2, 1, 3}, 1);
Expand Down

0 comments on commit 77a0e4e

Please sign in to comment.