Unverified Commit a1f3202c authored by Scott Cyphers's avatar Scott Cyphers Committed by GitHub

Convert missed ops to accept Output<Node> (#3539)

parent d8fbe52b
...@@ -21,10 +21,10 @@ using namespace ngraph; ...@@ -21,10 +21,10 @@ using namespace ngraph;
const string op::CTCGreedyDecoder::type_name{"CTCGreedyDecoder"}; const string op::CTCGreedyDecoder::type_name{"CTCGreedyDecoder"};
op::CTCGreedyDecoder::CTCGreedyDecoder(const shared_ptr<Node>& input, op::CTCGreedyDecoder::CTCGreedyDecoder(const Output<Node>& input,
const std::shared_ptr<Node>& seq_len, const Output<Node>& seq_len,
const bool ctc_merge_repeated) const bool ctc_merge_repeated)
: Op(check_single_output_args({input, seq_len})) : Op({input, seq_len})
, m_ctc_merge_repeated(ctc_merge_repeated) , m_ctc_merge_repeated(ctc_merge_repeated)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -33,8 +33,8 @@ namespace ngraph ...@@ -33,8 +33,8 @@ namespace ngraph
/// \param input Logits on which greedy decoding is performed /// \param input Logits on which greedy decoding is performed
/// \param seq_len Sequence lengths /// \param seq_len Sequence lengths
/// \param ctc_merge_repeated Whether to merge repeated labels /// \param ctc_merge_repeated Whether to merge repeated labels
CTCGreedyDecoder(const std::shared_ptr<Node>& input, CTCGreedyDecoder(const Output<Node>& input,
const std::shared_ptr<Node>& seq_len, const Output<Node>& seq_len,
const bool ctc_merge_repeated); const bool ctc_merge_repeated);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -21,14 +21,13 @@ using namespace ngraph; ...@@ -21,14 +21,13 @@ using namespace ngraph;
const string op::DetectionOutput::type_name{"DetectionOutput"}; const string op::DetectionOutput::type_name{"DetectionOutput"};
op::DetectionOutput::DetectionOutput(const std::shared_ptr<Node>& box_logits, op::DetectionOutput::DetectionOutput(const Output<Node>& box_logits,
const std::shared_ptr<Node>& class_preds, const Output<Node>& class_preds,
const std::shared_ptr<Node>& proposals, const Output<Node>& proposals,
const std::shared_ptr<Node>& aux_class_preds, const Output<Node>& aux_class_preds,
const std::shared_ptr<Node>& aux_box_preds, const Output<Node>& aux_box_preds,
const DetectionOutputAttrs& attrs) const DetectionOutputAttrs& attrs)
: Op(check_single_output_args( : Op({box_logits, class_preds, proposals, aux_class_preds, aux_box_preds})
{box_logits, class_preds, proposals, aux_class_preds, aux_box_preds}))
, m_attrs(attrs) , m_attrs(attrs)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -58,11 +58,11 @@ namespace ngraph ...@@ -58,11 +58,11 @@ namespace ngraph
/// \param aux_class_preds Auxilary class predictions /// \param aux_class_preds Auxilary class predictions
/// \param aux_box_preds Auxilary box predictions /// \param aux_box_preds Auxilary box predictions
/// \param attrs Detection Output attributes /// \param attrs Detection Output attributes
DetectionOutput(const std::shared_ptr<Node>& box_logits, DetectionOutput(const Output<Node>& box_logits,
const std::shared_ptr<Node>& class_preds, const Output<Node>& class_preds,
const std::shared_ptr<Node>& proposals, const Output<Node>& proposals,
const std::shared_ptr<Node>& aux_class_preds, const Output<Node>& aux_class_preds,
const std::shared_ptr<Node>& aux_box_preds, const Output<Node>& aux_box_preds,
const DetectionOutputAttrs& attrs); const DetectionOutputAttrs& attrs);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -23,10 +23,10 @@ using namespace ngraph; ...@@ -23,10 +23,10 @@ using namespace ngraph;
const string op::Interpolate::type_name{"Interpolate"}; const string op::Interpolate::type_name{"Interpolate"};
op::Interpolate::Interpolate(const std::shared_ptr<Node>& image, op::Interpolate::Interpolate(const Output<Node>& image,
const std::shared_ptr<Node>& output_shape, const Output<Node>& output_shape,
const InterpolateAttrs& attrs) const InterpolateAttrs& attrs)
: Op(check_single_output_args({image, output_shape})) : Op({image, output_shape})
, m_attrs(attrs) , m_attrs(attrs)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -44,8 +44,8 @@ namespace ngraph ...@@ -44,8 +44,8 @@ namespace ngraph
/// \param image Input image /// \param image Input image
/// \param output_shape Output shape of spatial axes /// \param output_shape Output shape of spatial axes
/// \param attrs Interpolation attributes /// \param attrs Interpolation attributes
Interpolate(const std::shared_ptr<Node>& image, Interpolate(const Output<Node>& image,
const std::shared_ptr<Node>& output_shape, const Output<Node>& output_shape,
const InterpolateAttrs& attrs); const InterpolateAttrs& attrs);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -23,10 +23,10 @@ using namespace ngraph; ...@@ -23,10 +23,10 @@ using namespace ngraph;
const string op::PriorBox::type_name{"PriorBox"}; const string op::PriorBox::type_name{"PriorBox"};
op::PriorBox::PriorBox(const shared_ptr<Node>& layer_shape, op::PriorBox::PriorBox(const Output<Node>& layer_shape,
const shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const PriorBoxAttrs& attrs) const PriorBoxAttrs& attrs)
: Op(check_single_output_args({layer_shape, image_shape})) : Op({layer_shape, image_shape})
, m_attrs(attrs) , m_attrs(attrs)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -57,8 +57,8 @@ namespace ngraph ...@@ -57,8 +57,8 @@ namespace ngraph
/// \param layer_shape Shape of layer for which prior boxes are computed /// \param layer_shape Shape of layer for which prior boxes are computed
/// \param image_shape Shape of image to which prior boxes are scaled /// \param image_shape Shape of image to which prior boxes are scaled
/// \param attrs PriorBox attributes /// \param attrs PriorBox attributes
PriorBox(const std::shared_ptr<Node>& layer_shape, PriorBox(const Output<Node>& layer_shape,
const std::shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const PriorBoxAttrs& attrs); const PriorBoxAttrs& attrs);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -23,10 +23,10 @@ using namespace ngraph; ...@@ -23,10 +23,10 @@ using namespace ngraph;
const string op::PriorBoxClustered::type_name{"PriorBoxClustered"}; const string op::PriorBoxClustered::type_name{"PriorBoxClustered"};
op::PriorBoxClustered::PriorBoxClustered(const shared_ptr<Node>& layer_shape, op::PriorBoxClustered::PriorBoxClustered(const Output<Node>& layer_shape,
const shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const PriorBoxClusteredAttrs& attrs) const PriorBoxClusteredAttrs& attrs)
: Op(check_single_output_args({layer_shape, image_shape})) : Op({layer_shape, image_shape})
, m_attrs(attrs) , m_attrs(attrs)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -55,8 +55,8 @@ namespace ngraph ...@@ -55,8 +55,8 @@ namespace ngraph
/// \param layer_shape Shape of layer for which prior boxes are computed /// \param layer_shape Shape of layer for which prior boxes are computed
/// \param image_shape Shape of image to which prior boxes are scaled /// \param image_shape Shape of image to which prior boxes are scaled
/// \param attrs PriorBoxClustered attributes /// \param attrs PriorBoxClustered attributes
PriorBoxClustered(const std::shared_ptr<Node>& layer_shape, PriorBoxClustered(const Output<Node>& layer_shape,
const std::shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const PriorBoxClusteredAttrs& attrs); const PriorBoxClusteredAttrs& attrs);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -23,11 +23,11 @@ using namespace ngraph; ...@@ -23,11 +23,11 @@ using namespace ngraph;
const string op::Proposal::type_name{"Proposal"}; const string op::Proposal::type_name{"Proposal"};
op::Proposal::Proposal(const std::shared_ptr<Node>& class_probs, op::Proposal::Proposal(const Output<Node>& class_probs,
const std::shared_ptr<Node>& class_logits, const Output<Node>& class_logits,
const std::shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const ProposalAttrs& attrs) const ProposalAttrs& attrs)
: Op(check_single_output_args({class_probs, class_logits, image_shape})) : Op({class_probs, class_logits, image_shape})
, m_attrs(attrs) , m_attrs(attrs)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -66,9 +66,9 @@ namespace ngraph ...@@ -66,9 +66,9 @@ namespace ngraph
/// \param class_logits Class prediction logits /// \param class_logits Class prediction logits
/// \param image_shape Shape of image /// \param image_shape Shape of image
/// \param attrs Proposal op attributes /// \param attrs Proposal op attributes
Proposal(const std::shared_ptr<Node>& class_probs, Proposal(const Output<Node>& class_probs,
const std::shared_ptr<Node>& class_logits, const Output<Node>& class_logits,
const std::shared_ptr<Node>& image_shape, const Output<Node>& image_shape,
const ProposalAttrs& attrs); const ProposalAttrs& attrs);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -21,15 +21,15 @@ using namespace ngraph; ...@@ -21,15 +21,15 @@ using namespace ngraph;
const string op::PSROIPooling::type_name{"PSROIPooling"}; const string op::PSROIPooling::type_name{"PSROIPooling"};
op::PSROIPooling::PSROIPooling(const shared_ptr<Node>& input, op::PSROIPooling::PSROIPooling(const Output<Node>& input,
const shared_ptr<Node>& coords, const Output<Node>& coords,
const size_t output_dim, const size_t output_dim,
const size_t group_size, const size_t group_size,
const float spatial_scale, const float spatial_scale,
int spatial_bins_x, int spatial_bins_x,
int spatial_bins_y, int spatial_bins_y,
const string& mode) const string& mode)
: Op(check_single_output_args({input, coords})) : Op({input, coords})
, m_output_dim(output_dim) , m_output_dim(output_dim)
, m_group_size(group_size) , m_group_size(group_size)
, m_spatial_scale(spatial_scale) , m_spatial_scale(spatial_scale)
......
...@@ -38,8 +38,8 @@ namespace ngraph ...@@ -38,8 +38,8 @@ namespace ngraph
/// \param spatial_bins_x Numbers of bins to divide the input feature maps over width /// \param spatial_bins_x Numbers of bins to divide the input feature maps over width
/// \param spatial_bins_y Numbers of bins to divide the input feature maps over height /// \param spatial_bins_y Numbers of bins to divide the input feature maps over height
/// \param mode Mode of pooling - Avg or Bilinear /// \param mode Mode of pooling - Avg or Bilinear
PSROIPooling(const std::shared_ptr<Node>& input, PSROIPooling(const Output<Node>& input,
const std::shared_ptr<Node>& coords, const Output<Node>& coords,
const size_t output_dim, const size_t output_dim,
const size_t group_size, const size_t group_size,
const float spatial_scale, const float spatial_scale,
......
...@@ -21,7 +21,7 @@ using namespace ngraph; ...@@ -21,7 +21,7 @@ using namespace ngraph;
const string op::RegionYolo::type_name{"RegionYolo"}; const string op::RegionYolo::type_name{"RegionYolo"};
op::RegionYolo::RegionYolo(const shared_ptr<Node>& input, op::RegionYolo::RegionYolo(const Output<Node>& input,
const size_t num_coords, const size_t num_coords,
const size_t num_classes, const size_t num_classes,
const size_t num_regions, const size_t num_regions,
...@@ -29,7 +29,7 @@ op::RegionYolo::RegionYolo(const shared_ptr<Node>& input, ...@@ -29,7 +29,7 @@ op::RegionYolo::RegionYolo(const shared_ptr<Node>& input,
const vector<int64_t>& mask, const vector<int64_t>& mask,
const int axis, const int axis,
const int end_axis) const int end_axis)
: Op(check_single_output_args({input})) : Op({input})
, m_num_coords(num_coords) , m_num_coords(num_coords)
, m_num_classes(num_classes) , m_num_classes(num_classes)
, m_num_regions(num_regions) , m_num_regions(num_regions)
......
...@@ -38,7 +38,7 @@ namespace ngraph ...@@ -38,7 +38,7 @@ namespace ngraph
/// \param mask Mask /// \param mask Mask
/// \param axis Axis to begin softmax on /// \param axis Axis to begin softmax on
/// \param end_axis Axis to end softmax on /// \param end_axis Axis to end softmax on
RegionYolo(const std::shared_ptr<Node>& input, RegionYolo(const Output<Node>& input,
const size_t num_coords, const size_t num_coords,
const size_t num_classes, const size_t num_classes,
const size_t num_regions, const size_t num_regions,
......
...@@ -21,8 +21,8 @@ using namespace ngraph; ...@@ -21,8 +21,8 @@ using namespace ngraph;
const string op::ReorgYolo::type_name{"ReorgYolo"}; const string op::ReorgYolo::type_name{"ReorgYolo"};
op::ReorgYolo::ReorgYolo(const shared_ptr<Node>& input, const Strides& strides) op::ReorgYolo::ReorgYolo(const Output<Node>& input, const Strides& strides)
: Op(check_single_output_args({input})) : Op({input})
, m_strides(strides) , m_strides(strides)
{ {
constructor_validate_and_infer_types(); constructor_validate_and_infer_types();
......
...@@ -32,7 +32,7 @@ namespace ngraph ...@@ -32,7 +32,7 @@ namespace ngraph
/// ///
/// \param input Input /// \param input Input
/// \param strides Stride to reorganize input by /// \param strides Stride to reorganize input by
ReorgYolo(const std::shared_ptr<Node>& input, const Strides& strides); ReorgYolo(const Output<Node>& input, const Strides& strides);
void validate_and_infer_types() override; void validate_and_infer_types() override;
......
...@@ -21,12 +21,12 @@ using namespace ngraph; ...@@ -21,12 +21,12 @@ 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 Output<Node>& input,
const shared_ptr<Node>& coords, const Output<Node>& coords,
const Shape& output_size, const Shape& output_size,
const float spatial_scale, const float spatial_scale,
const string& method) const string& method)
: Op(check_single_output_args({input, coords})) : Op({input, coords})
, m_output_size(output_size) , m_output_size(output_size)
, m_spatial_scale(spatial_scale) , m_spatial_scale(spatial_scale)
, m_method(method) , m_method(method)
......
...@@ -35,8 +35,8 @@ namespace ngraph ...@@ -35,8 +35,8 @@ namespace ngraph
/// \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 method Method of pooling - Max or Bilinear /// \param method Method of pooling - Max or Bilinear
ROIPooling(const std::shared_ptr<Node>& input, ROIPooling(const Output<Node>& input,
const std::shared_ptr<Node>& coords, const Output<Node>& coords,
const Shape& output_size, const Shape& output_size,
const float spatial_scale, const float spatial_scale,
const std::string& method); const std::string& 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