You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ex.extract_time("下周三")
Traceback (most recent call last):
File "", line 1, in
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/extractor.py", line 240, in extract_time
res = tn.parse(target=tmp_text) # target为待分析语句,timeBase为基准时间默认是当前时间
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeNormalizer.py", line 97, in parse
self.timeToken = self.__timeEx()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeNormalizer.py", line 176, in __timeEx
res.append(TimeUnit(temp[i], self, contextTp))
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 34, in init
self.time_normalization()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 53, in time_normalization
self.norm_setCurRelated()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 888, in norm_setCurRelated
cur = cur.replace(weeks=1, days=span)
File "/anaconda3/lib/python3.7/site-packages/arrow/arrow.py", line 603, in replace
raise AttributeError('unknown attribute: "{}"'.format(key))
AttributeError: unknown attribute: "weeks"
The text was updated successfully, but these errors were encountered:
ex.extract_time("下周三")
Traceback (most recent call last):
File "", line 1, in
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/extractor.py", line 240, in extract_time
res = tn.parse(target=tmp_text) # target为待分析语句,timeBase为基准时间默认是当前时间
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeNormalizer.py", line 97, in parse
self.timeToken = self.__timeEx()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeNormalizer.py", line 176, in __timeEx
res.append(TimeUnit(temp[i], self, contextTp))
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 34, in init
self.time_normalization()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 53, in time_normalization
self.norm_setCurRelated()
File "/anaconda3/lib/python3.7/site-packages/cocoNLP/config/basic/time_nlp/TimeUnit.py", line 888, in norm_setCurRelated
cur = cur.replace(weeks=1, days=span)
File "/anaconda3/lib/python3.7/site-packages/arrow/arrow.py", line 603, in replace
raise AttributeError('unknown attribute: "{}"'.format(key))
AttributeError: unknown attribute: "weeks"
The text was updated successfully, but these errors were encountered: