提交 25d76bc7 编写于 作者: W wanghaox

modify for add a space in maxout op

上级 4c113cc7
...@@ -47,7 +47,7 @@ class MaxOutFunctor<platform::CPUPlace, T> { ...@@ -47,7 +47,7 @@ class MaxOutFunctor<platform::CPUPlace, T> {
// T ele = maxout_process.initial(); // T ele = maxout_process.initial();
T ele = static_cast<T>(-FLT_MAX); T ele = static_cast<T>(-FLT_MAX);
for (int ph = 0; ph < groups; ++ph) { for (int ph = 0; ph < groups; ++ph) {
T x=input_data[(new_bindex+new_cindex) * groups+ph*fea_size+f]; T x = input_data[(new_bindex+new_cindex) * groups+ph*fea_size+f];
ele = ele > x ? ele : x; ele = ele > x ? ele : x;
} }
output_data[(new_bindex+new_cindex+f)] = ele; output_data[(new_bindex+new_cindex+f)] = ele;
......
...@@ -30,7 +30,7 @@ class MaxOutFunctor { ...@@ -30,7 +30,7 @@ class MaxOutFunctor {
public: public:
void operator()(const platform::DeviceContext& context, void operator()(const platform::DeviceContext& context,
const framework::Tensor& input, framework::Tensor * output, const framework::Tensor& input, framework::Tensor * output,
int groups ); int groups);
}; };
template <typename Place, class T> template <typename Place, class T>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册