Merge pull request from guoyinchen:aar-build-error-clang3.8

PiperOrigin-RevId: 251381063
This commit is contained in:
TensorFlower Gardener 2019-06-03 23:45:23 -07:00
commit b90587b9c1
2 changed files with 5 additions and 1 deletions

View File

@ -48,6 +48,7 @@ inline float CalculateResizeScale(int64 in_size, int64 out_size,
// Half pixel scaler scales assuming that the pixel centers are at 0.5, i.e. the
// floating point coordinates of the top,left pixel is 0.5,0.5.
struct HalfPixelScaler {
HalfPixelScaler(){};
inline float operator()(const int x, const float scale) const {
// Note that we subtract 0.5 from the return value, as the existing bilinear
// sampling code etc assumes pixels are in the old coordinate system.
@ -59,6 +60,7 @@ struct HalfPixelScaler {
// translation leading to inconsistent results. For example, a flip then a
// resize gives different results then a resize then a flip.
struct LegacyScaler {
LegacyScaler(){};
inline float operator()(const int x, const float scale) const {
return static_cast<float>(x) * scale;
}

View File

@ -37,6 +37,7 @@ namespace functor {
// output: [Di, ... , DN] where i belongs to set [1,N]
template <typename T, typename AccumT, typename BinaryFunctor>
struct ReduceOuterDimensions {
ReduceOuterDimensions(){};
template <int num_dims>
void operator()(const CPUDevice& device,
const Eigen::DSizes<Eigen::Index, num_dims>& input_dims,
@ -198,6 +199,7 @@ struct ReduceOuterDimensions {
// output: [Di, ... , Dj] where i & j belongs to set [1,N].
template <typename T, typename AccumT, typename BinaryFunctor, typename Reducer>
struct ReduceMiddleDimensions {
ReduceMiddleDimensions(){};
template <int num_dims>
void operator()(const CPUDevice& device,
const Eigen::DSizes<Eigen::Index, num_dims>& input_dims,
@ -256,7 +258,7 @@ struct ReduceMiddleDimensions {
using Input = Eigen::TensorMap<Eigen::Tensor<const T, 1>>;
Eigen::array<Eigen::Index, 1> reduction_axis = {0};
const Reducer reducer;
Reducer reducer;
const BinaryFunctor binary_op;
const auto compute = [inner_dim, middle_dim, input_data, buffer_data,