Closed nzal closed 7 years ago
Indeed I made small changes to that file, but not in the line in question. Could you check that your PYTHONPATH is set and that the theanolm/commands directory is installed somewhere along that path. I'll check if installing from pip still works.
I just tried installing with pip3 install --home TheanoLM
. The modules were installed to ~/.local/lib/python3.5/site-packages/theanolm
. Running the script ~/.local/bin/theanolm
worked even though I don't have that directory on my PYTHONPATH. By executing import sys; print(sys.path)
in Python interpreter, I can see that the package directory is included in the installation-dependent default paths. Since you have a working installation, you could compare in which directory the modules get installed and what you have in sys.path
in those two computers.
Thanks for the followup, it works fine, it was just a path issue.
I also have another question please, and thought might not be worthy to open anther Issue thread for. What is the expected format for the lattice decoding input? and how to generate the lattice structure? I am NOT working in ASR, I am modeling the various lemma options for lemma space, so I have the lemma options for each word in a file, and need to decode accordingly (generating nbest lists is vastly unfeasible), so I will need to generate the lattice structure myself.
It seems that a recent update messed up something in the pipeline. I installed the package a week ago using pip and it worked fine, installed it again on another machine yesterday and got this error when I was trying to use it. I noticed that there were some recent commits that may have caused it.
Traceback (most recent call last): File "/usr/local/bin/theanolm", line 8, in
from theanolm.commands import *
ImportError: No module named 'theanolm.commands'