Skip to content

the quantized form of Shape operation is not yet implemented #20955

@raninbowlalala

Description

@raninbowlalala

System information

  • Have I written custom code (as opposed to using a stock example script provided in TensorFlow):no
  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04):Linux Ubuntu 16.04
  • Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device:N/A
  • TensorFlow installed from (source or binary):source
  • TensorFlow version (use command below):1.9.0
  • Python version:2.7.3
  • Bazel version (if compiling from source):0.12.0
  • GCC/Compiler version (if compiling from source):c++11
  • CUDA/cuDNN version:7.5.18
  • GPU model and memory:TITAN,12GB
  • Exact command to reproduce:
    ./bazel-bin/tensorflow/contrib/lite/toco/toco --input_file=/deeplabv3_mobinetv2/frozen_inference_graph.pb --output_file=/deeplabv3_mobinetv2/foo.cc --input_format=TENSORFLOW_GRAPHDEF --output_format=TFLITE --inference_type=QUANTIZED_UINT8 --input_shape=1,513,513,3 --input_array=ImageTensor --output_array=logits/semantic/BiasAdd --default_ranges_min=0 --default_ranges_max=6 --mean_value=127.5 --std_value=127.5

Describe the problem

I want to use dummy quantization to quantize deeplabv3_mobilenetv2 model "mobilenetv2_coco_voc_trainaug" from https://github.com/tensorflow/models/blob/master/research/deeplab/g3doc/model_zoo.md.
But I got the shape operation is not yet implemented.
Do you have plan to implement it?

Source code / logs

2018-07-19 13:49:26.114180: F tensorflow/contrib/lite/toco/graph_transformations/quantize.cc:459] Unimplemented: this graph contains an operator of type Shape for which the quantized form is not yet implemented. Sorry, and patches welcome (that's a relatively fun patch to write, mostly providing the actual quantized arithmetic code for this op).
Aborted (core dumped)

Metadata

Metadata

Labels

comp:liteTF Lite related issuesstaleThis label marks the issue/pr stale - to be closed automatically if no activitystat:awaiting responseStatus - Awaiting response from authortype:featureFeature requests

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions