Yaxin commited on
Commit
546548a
1 Parent(s): 57bac50

Update SemEval2014Task4Raw.py

Browse files
Files changed (1) hide show
  1. SemEval2014Task4Raw.py +1 -1
SemEval2014Task4Raw.py CHANGED
@@ -166,7 +166,7 @@ class SemEvalXMLDataset():
166
  aspectTerms.append(aspectTermDict)
167
 
168
  # 从小到大排序
169
- aspectTerms.sort(key=lambda x: x["from"])
170
 
171
  aspectCategoriesXmlList = sentenceXml.getElementsByTagName("aspectCategory")
172
  aspectCategories = []
 
166
  aspectTerms.append(aspectTermDict)
167
 
168
  # 从小到大排序
169
+ aspectTerms.sort(key=lambda x: int(x["from"]))
170
 
171
  aspectCategoriesXmlList = sentenceXml.getElementsByTagName("aspectCategory")
172
  aspectCategories = []