Commit 2aa508b4 authored by Mateusz Bencer's avatar Mateusz Bencer Committed by Scott Cyphers

Adjust op ROIPooling (#3346)

* Adjust ROIPolling

* Fixed comment
parent 0850d234
...@@ -22,14 +22,14 @@ using namespace ngraph; ...@@ -22,14 +22,14 @@ using namespace ngraph;
const string op::ROIPooling::type_name{"ROIPooling"}; const string op::ROIPooling::type_name{"ROIPooling"};
op::ROIPooling::ROIPooling(const shared_ptr<Node>& input, op::ROIPooling::ROIPooling(const shared_ptr<Node>& input,
const std::shared_ptr<Node>& coords, const shared_ptr<Node>& coords,
const Shape& output_size, const Shape& output_size,
const float spatial_scale, const float spatial_scale,
const std::string& kind) const string& method)
: Op(check_single_output_args({input, coords})) : Op(check_single_output_args({input, coords}))
, m_output_size(output_size) , m_output_size(output_size)
, m_spatial_scale(spatial_scale) , m_spatial_scale(spatial_scale)
, m_kind(kind) , m_method(method)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
} }
...@@ -69,5 +69,5 @@ shared_ptr<Node> op::ROIPooling::copy_with_new_args(const NodeVector& new_args) ...@@ -69,5 +69,5 @@ shared_ptr<Node> op::ROIPooling::copy_with_new_args(const NodeVector& new_args)
{ {
check_new_args_count(this, new_args); check_new_args_count(this, new_args);
return make_shared<ROIPooling>( return make_shared<ROIPooling>(
new_args.at(0), new_args.at(1), m_output_size, m_spatial_scale, m_kind); new_args.at(0), new_args.at(1), m_output_size, m_spatial_scale, m_method);
} }
...@@ -34,12 +34,12 @@ namespace ngraph ...@@ -34,12 +34,12 @@ namespace ngraph
/// \param coords Coordinates of bounding boxes /// \param coords Coordinates of bounding boxes
/// \param output_size Height/Width of ROI output features /// \param output_size Height/Width of ROI output features
/// \param spatial_scale Ratio of input feature map over input image size /// \param spatial_scale Ratio of input feature map over input image size
/// \param kind Kind of pooling - Max or Bilinear /// \param method Method of pooling - Max or Bilinear
ROIPooling(const std::shared_ptr<Node>& input, ROIPooling(const std::shared_ptr<Node>& input,
const std::shared_ptr<Node>& coords, const std::shared_ptr<Node>& coords,
const Shape& output_size, const Shape& output_size,
const float spatial_scale, const float spatial_scale,
const std::string& kind); const std::string& method);
void validate_and_infer_types() override; void validate_and_infer_types() override;
...@@ -48,11 +48,11 @@ namespace ngraph ...@@ -48,11 +48,11 @@ namespace ngraph
const Shape& get_output_size() const { return m_output_size; } const Shape& get_output_size() const { return m_output_size; }
float get_spatial_scale() const { return m_spatial_scale; } float get_spatial_scale() const { return m_spatial_scale; }
const std::string& get_kind() const { return m_kind; } const std::string& get_method() const { return m_method; }
private: private:
Shape m_output_size; Shape m_output_size;
float m_spatial_scale; float m_spatial_scale;
std::string m_kind; std::string m_method;
}; };
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment