Getch the label from the node2 column, not the label column.
@@ -54,17 +54,17 @@ def load_property_labels_file(input_files: typing.List[str],
fail: bool = False
if kr.node1_column_idx < 0:
fail = True
- print("Cannot determine which column is the predicate in %s" % each_file, file=error_file, flush=True)
- if kr.label_column_idx < 0:
+ print("Cannot determine which column is node1 in %s" % each_file, file=error_file, flush=True)
+ if kr.node2_column_idx < 0:
fail = True
- print("Cannot determine which column is the label in %s" % each_file, file=error_file, flush=True)
+ print("Cannot determine which column is node2 in %s" % each_file, file=error_file, flush=True)
if fail:
raise KGTKException("Cannot identify a required column in %s" % each_file)
row: typing.List[str]
for row in kr:
node_id: str = row[kr.node1_column_idx]
- node_label: str = row[kr.label_column_idx]
+ node_label: str = row[kr.node2_column_idx]
text: str
language: str
language_suffix: str
