提交 8e241b08 编写于 作者: L liuruilong

format files

上级 0a93ea55
...@@ -111,9 +111,7 @@ class OperatorWithKernel : public OperatorBase<Dtype> { ...@@ -111,9 +111,7 @@ class OperatorWithKernel : public OperatorBase<Dtype> {
const VariableNameMap &outputs, const AttributeMap &attrs, const VariableNameMap &outputs, const AttributeMap &attrs,
std::shared_ptr<Scope> scope) std::shared_ptr<Scope> scope)
: OperatorBase<Dtype>(type, inputs, outputs, attrs, scope), : OperatorBase<Dtype>(type, inputs, outputs, attrs, scope),
param_(inputs, outputs, attrs, *scope) { param_(inputs, outputs, attrs, *scope) {}
}
virtual void RunImpl() const { this->kernel_.Compute(this->param_); } virtual void RunImpl() const { this->kernel_.Compute(this->param_); }
......
...@@ -200,9 +200,9 @@ Executor<Dtype, P>::Executor(const framework::Program<Dtype> p, int batch_size, ...@@ -200,9 +200,9 @@ Executor<Dtype, P>::Executor(const framework::Program<Dtype> p, int batch_size,
} }
std::shared_ptr<framework::BlockDesc> to_predict_block = std::shared_ptr<framework::BlockDesc> to_predict_block =
to_predict_program_->Block(0); to_predict_program_->Block(0);
auto &ops = ops_of_block_[*to_predict_block.get()]; auto &ops = ops_of_block_[*to_predict_block.get()];
for (const auto &op: ops) { for (const auto &op : ops) {
op->Init(); op->Init();
} }
} }
......
...@@ -110,7 +110,7 @@ void DecodeCenterSize(const framework::Tensor& target_box, ...@@ -110,7 +110,7 @@ void DecodeCenterSize(const framework::Tensor& target_box,
} }
template <> template <>
bool BoxCoderKernel<CPU, float>::Init(const BoxCoderParam &para) const { bool BoxCoderKernel<CPU, float>::Init(const BoxCoderParam& para) const {
return true; return true;
} }
......
...@@ -20,7 +20,8 @@ namespace paddle_mobile { ...@@ -20,7 +20,8 @@ namespace paddle_mobile {
namespace operators { namespace operators {
template <> template <>
bool ConvAddReluKernel<CPU, float>::Init(const FusionConvAddReluParam &para) const { bool ConvAddReluKernel<CPU, float>::Init(
const FusionConvAddReluParam &para) const {
return true; return true;
} }
......
...@@ -27,7 +27,8 @@ struct AddFunctor { ...@@ -27,7 +27,8 @@ struct AddFunctor {
}; };
template <> template <>
bool ElementwiseAddKernel<CPU, float>::Init(const ElementwiseAddParam &para) const { bool ElementwiseAddKernel<CPU, float>::Init(
const ElementwiseAddParam &para) const {
return true; return true;
} }
......
...@@ -206,7 +206,8 @@ void MultiClassOutput(const Tensor& scores, const Tensor& bboxes, ...@@ -206,7 +206,8 @@ void MultiClassOutput(const Tensor& scores, const Tensor& bboxes,
} }
template <> template <>
bool MultiClassNMSKernel<CPU, float>::Init(const MultiClassNMSParam &para) const { bool MultiClassNMSKernel<CPU, float>::Init(
const MultiClassNMSParam& para) const {
return true; return true;
} }
......
...@@ -35,7 +35,7 @@ namespace operators { ...@@ -35,7 +35,7 @@ namespace operators {
// } // }
template <> template <>
bool TransposeKernel<CPU, float>::Init(const TransposeParam &para) const { bool TransposeKernel<CPU, float>::Init(const TransposeParam& para) const {
return true; return true;
} }
......
...@@ -30,7 +30,7 @@ class BoxCoderKernel ...@@ -30,7 +30,7 @@ class BoxCoderKernel
: public framework::OpKernelBase<DeviceType, BoxCoderParam> { : public framework::OpKernelBase<DeviceType, BoxCoderParam> {
public: public:
void Compute(const BoxCoderParam& param) const; void Compute(const BoxCoderParam& param) const;
bool Init(const BoxCoderParam &para) const; bool Init(const BoxCoderParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -28,7 +28,7 @@ class FusionFcKernel ...@@ -28,7 +28,7 @@ class FusionFcKernel
: public framework::OpKernelBase<DeviceType, FusionFcParam> { : public framework::OpKernelBase<DeviceType, FusionFcParam> {
public: public:
void Compute(const FusionFcParam& param) const; void Compute(const FusionFcParam& param) const;
bool Init(const FusionFcParam &para) const; bool Init(const FusionFcParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -28,7 +28,7 @@ class MultiClassNMSKernel ...@@ -28,7 +28,7 @@ class MultiClassNMSKernel
: public framework::OpKernelBase<DeviceType, MultiClassNMSParam> { : public framework::OpKernelBase<DeviceType, MultiClassNMSParam> {
public: public:
void Compute(const MultiClassNMSParam& param) const; void Compute(const MultiClassNMSParam& param) const;
bool Init(const MultiClassNMSParam &para) const; bool Init(const MultiClassNMSParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -54,7 +54,7 @@ class PriorBoxKernel ...@@ -54,7 +54,7 @@ class PriorBoxKernel
: public framework::OpKernelBase<DeviceType, PriorBoxParam> { : public framework::OpKernelBase<DeviceType, PriorBoxParam> {
public: public:
void Compute(const PriorBoxParam& param) const; void Compute(const PriorBoxParam& param) const;
bool Init(const PriorBoxParam &para) const; bool Init(const PriorBoxParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -27,7 +27,7 @@ template <typename DeviceType, typename T> ...@@ -27,7 +27,7 @@ template <typename DeviceType, typename T>
class ReluKernel : public framework::OpKernelBase<DeviceType, ReluParam> { class ReluKernel : public framework::OpKernelBase<DeviceType, ReluParam> {
public: public:
void Compute(const ReluParam& param) const; void Compute(const ReluParam& param) const;
bool Init(const ReluParam &para) const; bool Init(const ReluParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -71,7 +71,7 @@ template <typename DeviceType, typename T> ...@@ -71,7 +71,7 @@ template <typename DeviceType, typename T>
class ReshapeKernel : public framework::OpKernelBase<DeviceType, ReshapeParam> { class ReshapeKernel : public framework::OpKernelBase<DeviceType, ReshapeParam> {
public: public:
void Compute(const ReshapeParam& param) const; void Compute(const ReshapeParam& param) const;
bool Init(const ReshapeParam &para) const; bool Init(const ReshapeParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -26,7 +26,7 @@ template <typename DeviceType, typename T> ...@@ -26,7 +26,7 @@ template <typename DeviceType, typename T>
class SigmoidKernel : public OpKernelBase<DeviceType, SigmoidParam> { class SigmoidKernel : public OpKernelBase<DeviceType, SigmoidParam> {
public: public:
void Compute(const SigmoidParam& param) const override; void Compute(const SigmoidParam& param) const override;
bool Init(const SigmoidParam &para) const; bool Init(const SigmoidParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
...@@ -29,7 +29,7 @@ class TransposeKernel ...@@ -29,7 +29,7 @@ class TransposeKernel
: public framework::OpKernelBase<DeviceType, TransposeParam> { : public framework::OpKernelBase<DeviceType, TransposeParam> {
public: public:
void Compute(const TransposeParam& param) const; void Compute(const TransposeParam& param) const;
bool Init(const TransposeParam &para) const; bool Init(const TransposeParam& para) const;
}; };
} // namespace operators } // namespace operators
} // namespace paddle_mobile } // namespace paddle_mobile
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册