提交 17402a0f 编写于 作者: C chenjiaoAngel

fix conflict

......@@ -15,6 +15,7 @@
#include <arm_neon.h>
#include "lite/backends/arm/math/conv_block_utils.h"
#include "lite/backends/arm/math/conv_depthwise.h"
#inlcude "lite/backends/arm/math/conv3x3s2p01_depthwise_fp32_relu.cc"
namespace paddle {
namespace lite {
......
......@@ -47,13 +47,6 @@ void PoolCompute::Run() {
bool use_quantizer = param.use_quantizer;
std::string& data_format = param.data_format;
<<<<<<< HEAD
bool pads_equal =
(paddings[0] == paddings[1]) && (paddings[2] == paddings[3]);
bool kps_equal = (ksize[0] == ksize[1]) && (strides[0] == strides[1]) &&
(paddings[0] == paddings[2]);
=======
bool pads_less =
(paddings[0] == paddings[2]) && (paddings[1] < 2) && (paddings[3] < 2);
......@@ -65,7 +58,7 @@ void PoolCompute::Run() {
bool global_pooling = (paddings[0] == 0) && (ksize[0] == in_dims[2]) &&
(ksize[1] == in_dims[3]) && kps_equal && pads_equal;
global_pooling = param.global_pooling || global_pooling;
>>>>>>> PaddlePaddle-develop1
if (global_pooling) {
for (size_t i = 0; i < ksize.size(); ++i) {
paddings[2 * i] = 0;
......@@ -96,10 +89,6 @@ void PoolCompute::Run() {
return;
}
} else {
<<<<<<< HEAD
if (ksize[0] == 2 && strides[0] == 2 && paddings[0] == 0 && pads_equal &&
kps_equal) {
=======
if (ksize[0] == 1 && strides[0] == 2 && paddings[0] == 0 && kps_equal) {
auto& ctx = this->ctx_->template As<ARMContext>();
if (pooling_type == "max") {
......@@ -118,7 +107,6 @@ void PoolCompute::Run() {
}
} else if (ksize[0] == 2 && strides[0] == 2 && paddings[0] == 0 &&
kps_equal) {
>>>>>>> PaddlePaddle-develop1
if (pooling_type == "max") {
lite::arm::math::pooling2x2s2_max(din,
dout,
......
......@@ -27,8 +27,6 @@ namespace cuda {
using Tensor = lite::Tensor;
using DDim = lite::DDim;
<<<<<<< HEAD
=======
#define IN(n, c, h, w) \
input_data[w + h * input_w + c * input_h * input_w + \
n * input_c * input_h * input_w]
......@@ -94,7 +92,6 @@ void nhwc2nchw_ref(lite::Tensor* input, lite::Tensor* output) {
}
}
>>>>>>> PaddlePaddle-develop1
static int PoolOutputSize(int input_size,
int filter_size,
int pad_left,
......
......@@ -64,7 +64,6 @@ int PoolConverter(void* ctx, OpLite* op, KernelBase* kernel) {
return FAILED;
}
<<<<<<< HEAD
auto padding = op_info->GetAttr<std::vector<int>>("paddings");
bool pads_equal = (padding[0] == padding[1]) && (padding[2] == padding[3]);
if (!pads_equal) {
......@@ -78,7 +77,7 @@ int PoolConverter(void* ctx, OpLite* op, KernelBase* kernel) {
int npu_ceil_mode = 0;
if (op_info->HasAttr("ceil_mode")) {
npu_ceil_mode = op_info->GetAttr<bool>("ceil_mode") ? 1 : 0;
=======
// pad mode
int pad_mode = 0;
std::string padding_algorithm("");
......@@ -89,7 +88,6 @@ int PoolConverter(void* ctx, OpLite* op, KernelBase* kernel) {
pad_mode = 6;
} else if (padding_algorithm == "VALID") {
pad_mode = 5;
>>>>>>> PaddlePaddle-develop1
}
// paddings and strides
......
......@@ -41,7 +41,6 @@ bool PoolOpLite::CheckShape() const {
return true;
}
<<<<<<< HEAD
inline void UpdatePadding(std::vector<int>* paddings,
const bool global_pooling,
const bool adaptive,
......@@ -75,8 +74,6 @@ inline void UpdatePadding(std::vector<int>* paddings,
}
}
=======
>>>>>>> PaddlePaddle-develop1
int PoolOutputSize(int input_size,
int filter_size,
int pad_left,
......
......@@ -14,10 +14,7 @@
#pragma once
<<<<<<< HEAD
=======
#include <algorithm>
>>>>>>> PaddlePaddle-develop1
#include <memory>
#include <string>
#include <vector>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册