TypeError: '_UserObject' object is not callable while loading tensorrt converted saved_model

Hello, I am trying to use tf-trt converted model for inference. model loading is done without any issue but calling model on image [prediction = model(image)] gives error.

TypeError: ‘_UserObject’ object is not callable.

Further inspecting methods for loaded model object using dir(model), there is no _ call _ method available.

Docker container:
nvcr.io/nvidia/tensorflow:23.02-tf2-py3

Machine learning algorithm : https://github.com/horovod/horovod/blob/master/examples/tensorflow2/tensorflow2_keras_mnist.py

tensorrt conversion:

can anyone reply on the question?

Looks like this might be the wrong category for your topic. I am moving this over to the TensorRt forum for better visibility,

1 Like