aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/graph_mobilenet.cpp2
-rw-r--r--utils/GraphUtils.h2
-rw-r--r--utils/ImageLoader.h3
3 files changed, 4 insertions, 3 deletions
diff --git a/examples/graph_mobilenet.cpp b/examples/graph_mobilenet.cpp
index 7533084d14..5a39dc0ffe 100644
--- a/examples/graph_mobilenet.cpp
+++ b/examples/graph_mobilenet.cpp
@@ -235,7 +235,7 @@ private:
};
graph << InputLayer(input_descriptor.set_quantization_info(in_quant_info),
- get_weights_accessor(data_path, common_params.image))
+ get_input_accessor(common_params, nullptr, false))
<< ConvolutionLayer(
3U, 3U, 32U,
get_weights_accessor(data_path, "Conv2d_0_weights.npy"),
diff --git a/utils/GraphUtils.h b/utils/GraphUtils.h
index 826ffff8c3..bc0822cc89 100644
--- a/utils/GraphUtils.h
+++ b/utils/GraphUtils.h
@@ -486,7 +486,7 @@ inline std::unique_ptr<graph::ITensorAccessor> get_input_accessor(const arm_comp
const std::string &image_file_lower = lower_string(image_file);
if(arm_compute::utility::endswith(image_file_lower, ".npy"))
{
- return arm_compute::support::cpp14::make_unique<NumPyBinLoader>(image_file);
+ return arm_compute::support::cpp14::make_unique<NumPyBinLoader>(image_file, graph_parameters.data_layout);
}
else if(arm_compute::utility::endswith(image_file_lower, ".jpeg")
|| arm_compute::utility::endswith(image_file_lower, ".jpg")
diff --git a/utils/ImageLoader.h b/utils/ImageLoader.h
index c03cbdf203..497320e326 100644
--- a/utils/ImageLoader.h
+++ b/utils/ImageLoader.h
@@ -257,7 +257,7 @@ public:
void fill_planar_tensor(T &tensor, bool bgr = false)
{
ARM_COMPUTE_ERROR_ON(!is_open());
- ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(&tensor, 1, DataType::U8, DataType::F32, DataType::F16);
+ ARM_COMPUTE_ERROR_ON_DATA_TYPE_CHANNEL_NOT_IN(&tensor, 1, DataType::U8, DataType::QASYMM8, DataType::F32, DataType::F16);
const DataLayout data_layout = tensor.info()->data_layout();
const TensorShape tensor_shape = tensor.info()->tensor_shape();
@@ -312,6 +312,7 @@ public:
switch(tensor.info()->data_type())
{
case DataType::U8:
+ case DataType::QASYMM8:
{
*(out.ptr() + 0 * stride_z) = bgr ? blue : red;
*(out.ptr() + 1 * stride_z) = green;