Hey, thanks for providing the code.
I am running one of the baseline model GconAttn. I am really confused about the concept2id part code.
For line 155 and line 156 in modelling_gconattn.py, the id of each concept are added by 1. The comment notes leave index 0 for padding. What I am confusing is that after adding 1, the index of a concept will be changed, and the corresponding embedding retrieved from the embedding matrix will no longer be correct. Did I miss something or my understanding is correct? Thank you so much for your kind help.
for data in tqdm(concept_data, total=n, desc='loading concepts'):
# leave index 0 for padding.
cur_qc = [self.concept2id[x] + 1 for x in data['qc']][:self.max_cpt_num].
cur_ac = [self.concept2id[x] + 1 for x in data['ac']][:self.max_cpt_num].
qc.append(cur_qc + [0] * (self.max_cpt_num - len(cur_qc))).
ac.append(cur_ac + [0] * (self.max_cpt_num - len(cur_ac)))
Hey, thanks for providing the code. I am running one of the baseline model GconAttn. I am really confused about the concept2id part code. For line 155 and line 156 in modelling_gconattn.py, the id of each concept are added by 1. The comment notes leave index 0 for padding. What I am confusing is that after adding 1, the index of a concept will be changed, and the corresponding embedding retrieved from the embedding matrix will no longer be correct. Did I miss something or my understanding is correct? Thank you so much for your kind help.