Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in test.py #1

Open
vikas-baghel opened this issue Jun 18, 2019 · 1 comment
Open

Error in test.py #1

vikas-baghel opened this issue Jun 18, 2019 · 1 comment

Comments

@vikas-baghel
Copy link

While running test.py file I am getting the following error.
raise ValueError('Unknown ' + printable_module_name + ': ' + class_name) ValueError: Unknown layer: ManhattanDistance
Can you help me what I am doing wrong??

@amanraj209
Copy link
Owner

Try this.
In the updated API, now you have pass the Custom Objects with a scope.

with tf.keras.utils.CustomObjectScope({'ManhattanDistance': ManhattanDistance}):
   model = tf.keras.models.load_model(os.path.join(ROOT_PATH, 'model/siamese-lstm-weights.h5'))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants