Open wanghaisheng opened 5 years ago
. (py2.7) ➜ TextGrapher git:(master) ✗ python text_grapher.py Traceback (most recent call last): File "text_grapher.py", line 407, in handler.main(content9) File "text_grapher.py", line 169, in main words, postags = self.process_sent(sent) File "text_grapher.py", line 47, in process_sent words, postags = self.parser.basic_process(sent) File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 161, in basic_process name_entity_dist = self.format_entity(words, netags, postags) File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 83, in format_entity name_entity_dist['nhs'] = self.modify_entity(name_entity_list, words, postags, 'nh') File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 100, in modify_entity consist = [words[int(start_index)] + '/' + postags[int(start_index)]] ValueError: invalid literal for int() with base 10: '' (py2.7) ➜ TextGrapher git:(master) ✗
himss2019all.txt
. (py2.7) ➜ TextGrapher git:(master) ✗ python text_grapher.py
handler.main(content9)
File "text_grapher.py", line 169, in main
words, postags = self.process_sent(sent)
File "text_grapher.py", line 47, in process_sent
words, postags = self.parser.basic_process(sent)
File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 161, in basic_process
name_entity_dist = self.format_entity(words, netags, postags)
File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 83, in format_entity
name_entity_dist['nhs'] = self.modify_entity(name_entity_list, words, postags, 'nh')
File "/Users/wanghaisheng/workspace/TextGrapher/sentence_parser.py", line 100, in modify_entity
consist = [words[int(start_index)] + '/' + postags[int(start_index)]]
ValueError: invalid literal for int() with base 10: ''
(py2.7) ➜ TextGrapher git:(master) ✗
Traceback (most recent call last): File "text_grapher.py", line 407, in