Error when running sematch
rmenendezm opened this issue · 6 comments
Hello,
My name is Raul and I am following the first step in the tutorial in order to use sematch but I kept getting the following error:
from sematch.semantic.similarity import WordNetSimilarity
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.5/dist-packages/sematch/semantic/similarity.py", line 25, in
from sematch.semantic.sparql import EntityFeatures, StatSPARQL
File "/usr/local/lib/python3.5/dist-packages/sematch/semantic/sparql.py", line 36
print query
^
SyntaxError: Missing parentheses in call to 'print'
Can you help me to fix this problem?
I have the same issue, that part of the code only seems to work on Python 2.7
https://github.com/brcordeiro/sematch seems to be fixed for python3 (according to the commit messages)
After a merge/pull-request that should be fixed, in the mean time it should be possible to fix it via
pip3 install git+git@github.com:brcordeiro/sematch.git
or pip3 install git+https://github.com/brcordeiro/sematch.git
I've just now created a pull request, #10
go this file : "/usr/local/lib/python3.5/dist-packages/sematch/semantic/sparql.py" and just comment out or correct the print, form print->print(), in python 3+ we need to have parenthesis which is missing here
Thank you! Easy change but working good.
This is still not working with Python 3.6.1 and sematch 1.0.4.