It fixes two generated test case failure
-reshape_weights_as_inputs
-reshape_quant8_weights_as_inputs
This patch adds sanity check if Inputs is not set.
Signed-off-by: Tanuj Tekriwal <tanuj.tekri@samsung.com>
{
auto setter = [&](::arm_compute::ITensor &tensor) { execution->source(n).push(tensor); };
- plan.operands().at(model.inputs.at(n)).access(setter);
+ // Some operand may not be defined at plan. Because some operands
+ // may be useless at ACL (ex. shape tensor for Reshape operator)
+ // So added a sanity check.
+ if (plan.operands().exist(model.inputs.at(n)))
+ {
+ plan.operands().at(model.inputs.at(n)).access(setter);
+ }
}
const auto &operations = execution->plan().operations();