From c1b6e37233e0ebd21cb44bf8863a09c0ba5feeb1 Mon Sep 17 00:00:00 2001 From: Gian Marco Date: Wed, 21 Feb 2018 18:03:26 +0000 Subject: COMPMID-765 - Call graph_init only once all nodes have been instantied - In order to enable to OpenCL tuner, graph_init() has to be called only once all nodes have been instantiated Change-Id: I28a51ccada8f81c12e4f4484b892f14a530f6f4d Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/121707 Reviewed-by: Georgios Pinitas Reviewed-by: Anthony Barbier Tested-by: Jenkins --- examples/graph_vgg16.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'examples/graph_vgg16.cpp') diff --git a/examples/graph_vgg16.cpp b/examples/graph_vgg16.cpp index eb8bd42e1a..c8cc5b2558 100644 --- a/examples/graph_vgg16.cpp +++ b/examples/graph_vgg16.cpp @@ -105,9 +105,6 @@ public: label = argv[4]; } - // Initialize graph - graph.graph_init(int_target_hint == 2); - graph << target_hint << convolution_hint << Tensor(TensorInfo(TensorShape(224U, 224U, 3U, 1U), 1, DataType::F32), @@ -228,6 +225,9 @@ public: // Softmax << SoftmaxLayer() << Tensor(get_output_accessor(label, 5)); + + // In order to enable the OpenCL tuner, graph_init() has to be called only when all nodes have been instantiated + graph.graph_init(int_target_hint == 2); } void do_run() override { -- cgit v1.2.1