Closed yoannapap closed 5 years ago
This seems to be due to a different version of Tensorflow. I use version 1.12.0 and it works fine with that. (https://www.tensorflow.org/versions/r1.12/api_docs/python/tf/math)
Closing this issue. Please update the tensorflow version to 1.12 or above.
Description
I was trying to run the following example code for the wn18 dataset (I only changed the regularizer form None to L2 because it was also giving me an error):
Train and evaluate an embedding model
import numpy as np from ampligraph.datasets import load_wn18 from ampligraph.latent_features import ComplEx from ampligraph.evaluation import evaluate_performance, mrr_score, hits_at_n_score
def main():
if name == "main": main()
Actual Behavior
And I have the following error:
------ Loss----- 2019-03-14 12:46:38,069 - ampligraph.latent_features.loss_functions - INFO - Name:pairwise Name: pairwise 2019-03-14 12:46:38,091 - ampligraph.latent_features.loss_functions - INFO - Parameters: Parameters: 2019-03-14 12:46:38,100 - ampligraph.latent_features.loss_functions - INFO - eta: eta : 10 2019-03-14 12:46:38,119 - ampligraph.latent_features.loss_functions - INFO - margin: margin : 1 ------ Regularizer----- 2019-03-14 12:46:38,149 - ampligraph.latent_features.regularizers - INFO - ------ Regularizer----- Name: L2 2019-03-14 12:46:38,158 - ampligraph.latent_features.regularizers - INFO - Name:L2 Parameters: 2019-03-14 12:46:38,162 - ampligraph.latent_features.regularizers - INFO - Parameters: 2019-03-14 12:46:38,163 - ampligraph.latent_features.regularizers - INFO - lambda:1e-05
lambda : 1e-05
AttributeError Traceback (most recent call last)