Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.
6595 토론

Error 5 with Slice layer on a custom TF network

idata
직원
1,340 조회수

Hi,

 

I am training a TF Net with TF v.1.3.0 and python2.7

 

When I try to compile the net with mvNCCompile -in img_n_cond -on gen/gen_op model_1.ckpt.meta

 

I get the following output

 

mvNCCompile v02.00, Copyright @ Movidius Ltd 2016 /usr/local/lib/python3.5/dist-packages/tensorflow/python/util/tf_inspect.py:45: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() instead if d.decorator_argspec is not None), _inspect.getargspec(target)) [Error 5] Toolkit Error: Stage Details Not Supported: Slice type not supported

 

I have the latest version of the ncsdk,

 

here's a snippet of the part of the net in question

 

self.img_n_cond = tf.get_variable(dtype = tf.float32, shape = [1, conf.img_size, 2*conf.img_size, conf.img_channel], name = "img_n_cond") print(self.img_n_cond.name) self.image = tf.slice(self.img_n_cond, begin = [0, 0, 0, 0], size = [1, conf.img_size, conf.img_size, conf.img_channel]) self.cond = tf.slice(self.img_n_cond, begin = [0, 0, conf.img_size, 0], size = [1, conf.img_size, conf.img_size, conf.img_channel])

 

I can see from the release notes that Slice is indeed supported, so I am not sure what the issue is.

0 포인트
6 응답
idata
직원
1,035 조회수

Hi,

 

I'm having the same issue, did you solve it?
0 포인트
idata
직원
1,035 조회수

Can someone finally comment on whether tf.slice is supported or not? The release says it is, but I get "[Error 5] Toolkit Error: Stage Details Not Supported: Slice type not supported"

0 포인트
idata
직원
1,035 조회수

Can someone finally comment on whether tf.slice is supported or not? The release note says it is, but I get "[Error 5] Toolkit Error: Stage Details Not Supported: Slice type not supported"

0 포인트
idata
직원
1,035 조회수

@mumes Slicing is supported but it expects all of the arguments to be a 4 dimensional input shape. The slice start point has to be the start of the tensor and the slice size has to be smaller than the input tensor. You can view the slice details in TensorFlowParser.py in /opt/movidius/NCSDK/ncsdk-x86_64/tk/Controllers

0 포인트
idata
직원
1,035 조회수

Thanks for the answer @Tome_at_Intel !

 

The release notes mention that a "Crop" operation is supported. Is that a Tensorflow operation?

0 포인트
idata
직원
1,035 조회수

@Tome_at_Intel Now that Slicing is supported, there's a really easy trick to have multiple inputs to the graph. Let's say you want to input two images image_1 and image_2 (shape = [32, 32, 3]) to the graph.

 

This could in cases like style transfer or something like Cycle-GAN.

 

You can set -in to be a node formed by concating the two images and taking slices inside the graph.

0 포인트
응답