Merge pull request #230 from mani-ananth/master

Fix for issue #221
This commit is contained in:
Haicheng Wu 2021-04-09 14:45:55 -04:00 committed by GitHub
commit c77a524459
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -357,9 +357,11 @@ public:
ReLu<ComputeFragment> relu;
if (Scale == ScaleType::NoBetaScaling)
intermediate = mul_add_source(beta_, converted_source); // X = beta * C + uniform
intermediate = converted_source;
else
intermediate = mul_add_accumulator(alpha_, converted_accumulator, intermediate); // D = alpha * Accum + X
intermediate = mul_add_source(beta_, converted_source); // X = beta * C + uniform
intermediate = mul_add_accumulator(alpha_, converted_accumulator, intermediate); // D = alpha * Accum + X
// Compute threshold optionally
intermediate = relu(threshold_, intermediate);