Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 0 additions & 78 deletions runtime/compute/cker/include/cker/operation/MatrixBandPart.h

This file was deleted.

19 changes: 0 additions & 19 deletions runtime/onert/backend/cpu/KernelGenerator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@
#include "ops/UnpackLayer.h"
#include "ops/SquaredDiffLayer.h"
#include "ops/L2NormLayer.h"
#include "ops/MatrixBandPartLayer.h"
#include "ops/BatchMatMulLayer.h"
#include "ops/BroadcastToLayer.h"
#include "ops/FusedBatchNormLayer.h"
Expand Down Expand Up @@ -1132,24 +1131,6 @@ void KernelGenerator::visit(const ir::operation::Tile &node)
_return_fn = std::move(fn);
}

void KernelGenerator::visit(const ir::operation::MatrixBandPart &node)
{
const auto output_index{node.getOutputs().at(0)};
const auto input_index{node.getInputs().at(ir::operation::MatrixBandPart::INPUT)};
const auto num_lower_index{node.getInputs().at(ir::operation::MatrixBandPart::NUM_LOWER_DIAG)};
const auto num_upper_index{node.getInputs().at(ir::operation::MatrixBandPart::NUM_UPPER_DIAG)};

auto output_tensor = _tensor_reg->getPortableTensor(output_index);
auto input_tensor = _tensor_reg->getPortableTensor(input_index);
auto num_lower_tensor = _tensor_reg->getPortableTensor(num_lower_index);
auto num_upper_tensor = _tensor_reg->getPortableTensor(num_upper_index);

auto fn = std::make_unique<ops::MatrixBandPartLayer>();

fn->configure(input_tensor, num_lower_tensor, num_upper_tensor, output_tensor);
_return_fn = std::move(fn);
}

void KernelGenerator::visit(const ir::operation::DetectionPostProcess &node)
{
using NMS = ir::operation::DetectionPostProcess;
Expand Down
1 change: 0 additions & 1 deletion runtime/onert/backend/cpu/KernelGenerator.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ class KernelGenerator : public basic::KernelGeneratorBase
void visit(const ir::operation::L2Normalization &) override;
void visit(const ir::operation::LogSoftmax &) override;
void visit(const ir::operation::LSTM &) override;
void visit(const ir::operation::MatrixBandPart &) override;
void visit(const ir::operation::DetectionPostProcess &) override;
void visit(const ir::operation::OneHot &) override;
void visit(const ir::operation::Pack &) override;
Expand Down
81 changes: 0 additions & 81 deletions runtime/onert/backend/cpu/ops/MatrixBandPartLayer.cc

This file was deleted.

51 changes: 0 additions & 51 deletions runtime/onert/backend/cpu/ops/MatrixBandPartLayer.h

This file was deleted.

1 change: 0 additions & 1 deletion runtime/onert/core/include/compiler/StaticShapeInferer.h
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,6 @@ class StaticShapeInferer : public ir::OperationVisitor
void visit(const ir::operation::L2Normalization &op) override;
void visit(const ir::operation::Loss &op) override;
void visit(const ir::operation::LSTM &op) override;
void visit(const ir::operation::MatrixBandPart &op) override;
void visit(const ir::operation::OneHot &op) override;
void visit(const ir::operation::Pack &op) override;
void visit(const ir::operation::Pad &op) override;
Expand Down
1 change: 0 additions & 1 deletion runtime/onert/core/include/exec/DynamicShapeInferer.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ class DynamicShapeInferer : public ir::OperationVisitor
void visit(const ir::operation::Gather &op) override;
void visit(const ir::operation::L2Normalization &op) override;
void visit(const ir::operation::LSTM &op) override;
void visit(const ir::operation::MatrixBandPart &op) override;
void visit(const ir::operation::DetectionPostProcess &op) override;
void visit(const ir::operation::OneHot &op) override;
void visit(const ir::operation::Pack &op) override;
Expand Down
1 change: 0 additions & 1 deletion runtime/onert/core/include/ir/Operations.Include.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
#include "ir/operation/LogSoftmax.h"
#include "ir/operation/Loss.h"
#include "ir/operation/LSTM.h"
#include "ir/operation/MatrixBandPart.h"
#include "ir/operation/DetectionPostProcess.h"
#include "ir/operation/OneHot.h"
#include "ir/operation/Pack.h"
Expand Down
1 change: 0 additions & 1 deletion runtime/onert/core/include/ir/Operations.lst
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ OP(L2Normalization)
OP(LocalResponseNormalization)
OP(LogSoftmax)
OP(LSTM)
OP(MatrixBandPart)
OP(DetectionPostProcess)
OP(OneHot)
OP(Pack)
Expand Down
47 changes: 0 additions & 47 deletions runtime/onert/core/include/ir/operation/MatrixBandPart.h

This file was deleted.

19 changes: 0 additions & 19 deletions runtime/onert/core/src/compiler/ShapeValidator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1111,25 +1111,6 @@ void ShapeValidator::visit(const ir::operation::Range &node)
OP_REQUIRES(operands.at(delta_index).shape().rank() == 0);
}

void ShapeValidator::visit(const ir::operation::MatrixBandPart &node)
{
const auto &operands = _graph.operands();
const auto output_index{node.getOutputs().at(0)};
const auto input_index{node.getInputs().at(ir::operation::MatrixBandPart::Input::INPUT)};
const auto num_lower_index{
node.getInputs().at(ir::operation::MatrixBandPart::Input::NUM_LOWER_DIAG)};
const auto num_upper_index{
node.getInputs().at(ir::operation::MatrixBandPart::Input::NUM_UPPER_DIAG)};

// Check for dimension constraints
if (operands.at(output_index).info().isDynamic())
return;

OP_REQUIRES(operands.at(input_index).shape().rank() >= 2); // input must be more than 2 dim matrix
OP_REQUIRES(operands.at(num_upper_index).shape().rank() == 0); // num_lower must be scalar
OP_REQUIRES(operands.at(num_lower_index).shape().rank() == 0); // num_upper must be scalar
}

void ShapeValidator::visit(const ir::operation::LogSoftmax &node)
{
const auto &operands = _graph.operands();
Expand Down
1 change: 0 additions & 1 deletion runtime/onert/core/src/compiler/ShapeValidator.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ class ShapeValidator : public ir::OperationVisitor
void visit(const ir::operation::SquaredDifference &node) override;
void visit(const ir::operation::Tile &node) override;
void visit(const ir::operation::Range &node) override;
void visit(const ir::operation::MatrixBandPart &node) override;
void visit(const ir::operation::LogSoftmax &node) override;
void visit(const ir::operation::RmsNorm &node) override;
void visit(const ir::operation::RoPE &node) override;
Expand Down
5 changes: 0 additions & 5 deletions runtime/onert/core/src/compiler/StaticShapeInferer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -745,11 +745,6 @@ void StaticShapeInferer::visit(const ir::operation::LSTM &op)
}
}

void StaticShapeInferer::visit(const ir::operation::MatrixBandPart &op)
{
handleSimpleUnaryOp(op, op.getInputs().at(ir::operation::MatrixBandPart::Input::INPUT));
}

void StaticShapeInferer::visit(const ir::operation::OneHot &op)
{
auto &operands = _lowered_subg->graph().operands();
Expand Down
5 changes: 0 additions & 5 deletions runtime/onert/core/src/exec/DynamicShapeInferer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -594,11 +594,6 @@ void DynamicShapeInferer::visit(const ir::operation::LSTM &op)
}
}

void DynamicShapeInferer::visit(const ir::operation::MatrixBandPart &op)
{
handleSimpleUnaryOp(op, op.getInputs().at(ir::operation::MatrixBandPart::INPUT));
}

void DynamicShapeInferer::visit(const ir::operation::DetectionPostProcess & /* op */)
{
// NOTE DetectionPostProcess's undefined outputs' shape are decided on compile time
Expand Down
Loading