Issue Running Inference with YOLOX Model Quantized with PyTorch

I am trying to run inference with a YOLOX model quantized by PyTorch Quantization Aware Training with TVM. However, when I convert quantized PyTorch model to relay and run optimizations, I get the following warnings:

[19:22:41] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:41] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:41] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:41] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:41] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:42] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:22:43] /home/benjamin-gilby/tvm_env/tvm/src/relay/backend/vm/compiler.cc:1194: All lowered functions have been build by BYOC -- generating an empty TVM module
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound
[19:24:21] /home/benjamin-gilby/tvm_env/tvm/include/tvm/topi/transform.h:1080: Warning: Fast mode segfaults when there are out-of-bounds indices. Make sure input indices are in bound

Then, during inference, there are overflow warnings, inference is slow, and the model shows a mAP of 0.

Running inference with PyTorch works fine. Also, I’ve tried targeting llvm and cuda (same result for both), so I am not sure why BYOC is mentioned.

Does anyone have insight into these warnings? I could not find any previous posts mentioning them.

1 Like

Have you solved this problem? I have also encountered similar problems recently

1 Like