Recurrent-Knowledge-Graph-Embedding
Recurrent-Knowledge-Graph-Embedding copied to clipboard
How can I deal with the problem in the LSTMTrain.py?
Hello,when I run your code,I get the Error in the LSTMTrain.py as below: "UnboundLocalError:local variable 'ur_id' referenced before assignment". Then I add the code "global ur_id" at the first line of "dump_post_embedding" function, but I received another error “NameError:name 'usr_id' is not defined. How can I handle this problem?
I have solved this problem, I replaced the ur_id=ur_id.cuda() by node_id=node_id.cuda() in the LSTMTrain.py