auto &factory = OperationFactory::instance();
OperationFactory::Param param{inputCount, inputs, outputCount, outputs};
- switch (type)
- {
- case ANEURALNETWORKS_CAST_EX:
- {
- auto node = factory.create(type, param);
- _model->addOperation(std::unique_ptr<neurun::model::operation::Node>{node});
-
- break;
- }
- default:
- throw std::runtime_error{"Not supported operation"};
- }
+ auto node = factory.create(type, param);
+ _model->addOperation(std::unique_ptr<neurun::model::operation::Node>{node});
}
catch (const std::exception &e)
{