I’m having trouble reading the KGCN open source code used for recommendations.In the train method of the source code, the following statements were used for training the model:
# KGCN is a custom classes
model = KGCN(args, n_user, n_entity, n_relation, adj_entity, adj_relation)
with tf.Session() as sess:
for step in range(args.n_epochs):
_, loss = model.train(sess, get_feed_dict(model, train_data, start, start+args.batch_size))
But the model.train is defined as:
def train(self, sess, feed_dict):
return sess.run([self.optimizer, self.loss], feed_dict)
So how are the project feature vectors and user feature vectors updated, and how is the loss of the model updated?
Please let me know if you need the source code.