diff options
author | Benoit Steiner <benoit.steiner.goog@gmail.com> | 2016-05-10 12:25:27 -0700 |
---|---|---|
committer | Benoit Steiner <benoit.steiner.goog@gmail.com> | 2016-05-10 12:25:27 -0700 |
commit | 661e710092024e222ba88ddbe1e025b3d730ebef (patch) | |
tree | 88cdc09a57ceb86ebecb0800794f76977fcf2779 /unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h | |
parent | 0eb69b7552efe0194c2c96ce8dee09176c49c231 (diff) |
Added support for fp16 to the sigmoid functor.
Diffstat (limited to 'unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h')
-rw-r--r-- | unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h b/unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h index 33cd00391..631096191 100644 --- a/unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h +++ b/unsupported/Eigen/CXX11/src/Tensor/TensorFunctors.h @@ -69,7 +69,7 @@ struct scalar_sigmoid_op { template <typename Packet> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Packet packetOp(const Packet& x) const { - const Packet one = pset1<Packet>(1); + const Packet one = pset1<Packet>(T(1)); return pdiv(one, padd(one, pexp(pnegate(x)))); } }; |