| 35 | } |
| 36 | |
| 37 | void SliceLayer::ValidateTensorShapesFromInputs() |
| 38 | { |
| 39 | VerifyLayerConnections(1, CHECK_LOCATION()); |
| 40 | |
| 41 | const TensorShape& outputShape = GetOutputSlot(0).GetTensorInfo().GetShape(); |
| 42 | |
| 43 | VerifyShapeInferenceType(outputShape, m_ShapeInferenceMethod); |
| 44 | |
| 45 | auto inferredShapes = InferOutputShapes({ GetInputSlot(0).GetTensorInfo().GetShape() }); |
| 46 | |
| 47 | if (inferredShapes.size() != 1) |
| 48 | { |
| 49 | throw armnn::LayerValidationException("inferredShapes has " |
| 50 | + std::to_string(inferredShapes.size()) + |
| 51 | " elements - should only have 1."); |
| 52 | } |
| 53 | |
| 54 | ValidateAndCopyShape(outputShape, inferredShapes[0], m_ShapeInferenceMethod, "SliceLayer"); |
| 55 | } |
| 56 | |
| 57 | std::vector<TensorShape> SliceLayer::InferOutputShapes(const std::vector<TensorShape>& inputShapes) const |
| 58 | { |
nothing calls this directly
no test coverage detected