diff --git a/examples/arm/executor_runner/arm_executor_runner.cpp b/examples/arm/executor_runner/arm_executor_runner.cpp index e9c758a60ba..2d08f733eba 100644 --- a/examples/arm/executor_runner/arm_executor_runner.cpp +++ b/examples/arm/executor_runner/arm_executor_runner.cpp @@ -295,6 +295,9 @@ Result prepare_input_tensors( case ScalarType::Float: t.mutable_data_ptr()[j] = 1.; break; + case ScalarType::Char: + t.mutable_data_ptr()[j] = 1; + break; } } } @@ -584,12 +587,18 @@ int main(int argc, const char* argv[]) { i, j, outputs[i].toTensor().const_data_ptr()[j]); - } else { + } else if (t.scalar_type() == ScalarType::Float) { printf( "Output[%d][%d]: %f\n", i, j, outputs[i].toTensor().const_data_ptr()[j]); + } else if (t.scalar_type() == ScalarType::Char) { + printf( + "Output[%d][%d]: %d\n", + i, + j, + outputs[i].toTensor().const_data_ptr()[j]); } } #if defined(ET_EVENT_TRACER_ENABLED)