-
-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Inference against a corpus is segfaulting #181
Comments
It seems like my |
Hi, @erip |
@bab2min are you using the WSTok here? It should cause the error |
Ooops sorry @erip , I forgot this feed entirely. class WSTok:
def __call__(self, raw, **kwargs):
return raw.split()
docs = ["this is test text", "this is another text", "somewhat long text...."]
corpus = tp.utils.Corpus(tokenizer=WSTok(), stopwords=[])
corpus.process(doc for doc in docs)
for doc in corpus:
print(doc)
# it will print
# <tomotopy.Document with words="this is test text">
# <tomotopy.Document with words="this is another text">
# <tomotopy.Document with words="somewhat long text...."> I suspect that some lines in the |
I am migrating away from
model.make_doc
totp.util.Corpus
and am finding that using Corpus segfaults. My tiny repro is here:When I run this, I see:
Running this with
catchsegv
shows these relevant lines:which seems to point here... maybe
d.get()
is null?The text was updated successfully, but these errors were encountered: