ship class Object detection with custom model weights
You should be able to use keras.models.load_model to load the hdf5 model file. See also the tensorflow documentation.
# saving the model
model = ...  # Get model (Sequential, Functional Model, or Model subclass)
model.save('weights.hdf5')

# loading the model
from tensorflow import keras
model = keras.models.load_model('weights.hdf5')