automl
automl copied to clipboard
custom trained model inference issue on single image
python3 model_inspect.py --runmode=infer --model_name='efficientdet-d0' --hparams="image_size=600x400" --max_boxes_to_draw=100 --min_score_thresh=0.4 --ckpt_path=/home/angad/puretech/automl/efficientdet/model_weights/efficientdet-d0-train-eval-08/ --input_image=/home/angad/puretech/automl/efficientdet/testdata/men-who-love-dogs.jpg --output_image_dir=/home/angad/puretech/automl/efficientdet/testdata/
2021-10-25 16:43:20.608362: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'libcudart.so.11.0'; dlerror: libcudart.so.11.0: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /opt/intel/openvino_2021/data_processing/dl_streamer/lib:/opt/intel/openvino_2021/data_processing/gstreamer/lib:/opt/intel/openvino_2021/opencv/lib:/opt/intel/openvino_2021/deployment_tools/ngraph/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/tbb/lib::/opt/intel/openvino_2021/deployment_tools/inference_engine/external/hddl/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/omp/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/gna/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/mkltiny_lnx/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/lib/intel64 2021-10-25 16:43:20.608406: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine. 2021-10-25 16:43:29.540458: I tensorflow/compiler/jit/xla_cpu_device.cc:41] Not creating XLA devices, tf_xla_enable_xla_devices not set 2021-10-25 16:43:29.540712: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /opt/intel/openvino_2021/data_processing/dl_streamer/lib:/opt/intel/openvino_2021/data_processing/gstreamer/lib:/opt/intel/openvino_2021/opencv/lib:/opt/intel/openvino_2021/deployment_tools/ngraph/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/tbb/lib::/opt/intel/openvino_2021/deployment_tools/inference_engine/external/hddl/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/omp/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/gna/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/external/mkltiny_lnx/lib:/opt/intel/openvino_2021/deployment_tools/inference_engine/lib/intel64 2021-10-25 16:43:29.540733: W tensorflow/stream_executor/cuda/cuda_driver.cc:326] failed call to cuInit: UNKNOWN ERROR (303) 2021-10-25 16:43:29.540776: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (deepedge): /proc/driver/nvidia/version does not exist 2021-10-25 16:43:29.541233: I tensorflow/compiler/jit/xla_gpu_device.cc:99] Not creating XLA devices, tf_xla_enable_xla_devices not set WARNING:tensorflow:From /home/angad/puretech/automl/efficientdet/utils.py:602: The name tf.keras.layers.enable_v2_dtype_behavior is deprecated. Please use tf.compat.v1.keras.layers.enable_v2_dtype_behavior instead.
W1025 16:43:29.605655 140598559053632 module_wrapper.py:138] From /home/angad/puretech/automl/efficientdet/utils.py:602: The name tf.keras.layers.enable_v2_dtype_behavior is deprecated. Please use tf.compat.v1.keras.layers.enable_v2_dtype_behavior instead.
2021-10-25 16:43:38.495527: I tensorflow/compiler/mlir/mlir_graph_optimization_pass.cc:196] None of the MLIR optimization passes are enabled (registered 0 passes) 2021-10-25 16:43:38.623149: I tensorflow/core/platform/profile_utils/cpu_utils.cc:112] CPU Frequency: 2494300000 Hz WARNING:tensorflow:From /home/angad/.virtualenvs/puretech/lib/python3.6/site-packages/tensorflow/python/training/moving_averages.py:458: Variable.initialized_value (from tensorflow.python.ops.variables) is deprecated and will be removed in a future version. Instructions for updating: Use Variable.read_value. Variables in 2.X are initialized automatically both in eager and graph (inside tf.defun) contexts. W1025 16:43:39.938584 140598559053632 deprecation.py:339] From /home/angad/.virtualenvs/puretech/lib/python3.6/site-packages/tensorflow/python/training/moving_averages.py:458: Variable.initialized_value (from tensorflow.python.ops.variables) is deprecated and will be removed in a future version. Instructions for updating: Use Variable.read_value. Variables in 2.X are initialized automatically both in eager and graph (inside tf.defun) contexts. Traceback (most recent call last): File "/home/angad/.virtualenvs/puretech/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1375, in _do_call return fn(*args) File "/home/angad/.virtualenvs/puretech/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1360, in _run_fn target_list, run_metadata) File "/home/angad/.virtualenvs/puretech/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1453, in _call_tf_sessionrun run_metadata) tensorflow.python.framework.errors_impl.InvalidArgumentError: Input to reshape is a tensor with 40014 values, but the requested shape requires a multiple of 90 [[{{node Reshape_4}}]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "model_inspect.py", line 521, in
Errors may have originated from an input operation. Input Source operations connected to node Reshape_4: class_net/class-predict_2/BiasAdd (defined at /home/angad/puretech/automl/efficientdet/tf2/efficientdet_keras.py:457)
Original stack trace for 'Reshape_4':
File "model_inspect.py", line 521, in
I am having the same issue. May I know how did you solve it?
Same issue.