# Create model in inference mode import tensorflow as tf from tensorflow import keras with tf.device(DEVICE): model = modellib.MaskRCNN(mode="inference", model_dir=MODEL_DIR,
config=config)`
# load the last best model you trained
# weights_path = model.find_last()[1]
custom_WEIGHTS_PATH = '/home/unni/my_project_work/car-damage-detection-using-CNN-master/logs/scratch20190612T2046/mask_rcnn_scratch_0013.h5'
# Load weights print("Loading weights ", custom_WEIGHTS_PATH) model.load_weights(custom_WEIGHTS_PATH, by_name=True)`
This is the error AttributeError: in user code:
/home/unni/my_project_work/car-damage-detection-using-CNN-master/mrcnn/model.py:391 call *
roi_level = log2_graph(tf.sqrt(h * w) / (224.0 / tf.sqrt(image_area)))
/home/unni/my_project_work/car-damage-detection-using-CNN-master/mrcnn/model.py:342 log2_graph *
return tf.log(x) / tf.log(2.0)
Please help