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
It seems that the important_doc is None, and NoneType cannot be iterated.
Well, I didn't learn so much of TextRank Algorithm, and I am trying to go on to work. Maybe someone can tell what is happening?
PS: Sorry that I could not afford the test case I was using, for it is full of Chinese name. (If someone ask me privately, maybe i could.) Anyway, there is a bug in it. For some reason the most_important_docs at line 212, summarizer.py is None. This situation should be handled properly. I suppose that summarize() should return None or raise some other Error for debugging when most_important_docs is None. Or even better, optimize the implementation of TextRank Algorithm, which is fully out of my ability for now...
>>>s='`a string full of different Chinese name, with the number of more than 1 thousand.`'>>>importgensim.summarizationasgsum>>>gsum.summarize(s)
The text was updated successfully, but these errors were encountered:
Description:
I was working on a set of Chinese sentences. And when I call the function
gensim.summarization.summarize()
.The Error below was occurred:It seems that the important_doc is None, and NoneType cannot be iterated.
Well, I didn't learn so much of TextRank Algorithm, and I am trying to go on to work. Maybe someone can tell what is happening?
PS: Sorry that I could not afford the test case I was using, for it is full of Chinese name. (If someone ask me privately, maybe i could.) Anyway, there is a bug in it. For some reason the
most_important_docs
at line 212,summarizer.py
isNone
. This situation should be handled properly. I suppose that summarize() should return None or raise some other Error for debugging whenmost_important_docs
isNone
. Or even better, optimize the implementation of TextRank Algorithm, which is fully out of my ability for now...The text was updated successfully, but these errors were encountered: