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
Running df1 = text2term.map_terms("test/unstruct_terms.txt", "http://www.ebi.ac.uk/efo/efo.owl")
Gave me an error which is something like
.....
File "/MY_PATH_TO/text2term/tfidf_mapper.py", line 50, in _tokenize
vocabulary = count_vectorizer.fit(source_terms + target_labels).vocabulary_
....
File "/MY_PATH_TO/sklearn/feature_extraction/text.py", line 69, in _preprocess
doc = doc.lower()
^^^^^^^^^
AttributeError: 'float' object has no attribute 'lower'
The problem seems to be caused by giving count_vectorizer.fit a list including a float.
I guess a float value is somewhere in EFO.
Changing the above code to df1 = text2term.map_terms("test/unstruct_terms.txt", "http://purl.obolibrary.org/obo/cl.owl")
worked.
The text was updated successfully, but these errors were encountered:
There is indeed a bug in the t2t input handler, which throws this error when an ontology term label or synonym is not a string. In this case, there is a synonym 92.1 for a term in EFO that is causing the issue.
A bug fix will be released, either today or tomorrow, to address this issue.
Running
df1 = text2term.map_terms("test/unstruct_terms.txt", "http://www.ebi.ac.uk/efo/efo.owl")
Gave me an error which is something like
The problem seems to be caused by giving
count_vectorizer.fit
a list including a float.I guess a float value is somewhere in EFO.
Changing the above code to
df1 = text2term.map_terms("test/unstruct_terms.txt", "http://purl.obolibrary.org/obo/cl.owl")
worked.
The text was updated successfully, but these errors were encountered: