* Report the error thrown
Signed-off-by: Sadik Armagan <sadik.armagan@arm.com>
Change-Id: If5e5160f43c11a284b919d76b04d9c4d53e9c56c
// Extract target shape from input
auto bufferPtr = GetBuffer(m_Model, inputs[1]->buffer);
auto values = reinterpret_cast<const int32_t*>(bufferPtr->data.data());
+ if (!values)
+ {
+ ARMNN_THROW_PARSE_EXCEPTION("Reshape operator target shape input buffer data is null");
+ }
for (int i=0; i < inputs[1]->shape[0]; ++i)
{
targetShape.push_back(values[i]);
armnnDelegate::TfLiteArmnnDelegateDelete);
// Register armnn_delegate to TfLiteInterpreter
int status = tfLiteInterpreter->ModifyGraphWithDelegate(std::move(theArmnnDelegate));
+ if (status == kTfLiteError)
+ {
+ ARMNN_LOG(fatal) << "Could not register ArmNN TfLite Delegate to TfLiteInterpreter!";
+ return EXIT_FAILURE;
+ }
std::vector<std::string> inputBindings;
for (const std::string& inputName: params.m_InputNames)