Parser-v2 icon indicating copy to clipboard operation
Parser-v2 copied to clipboard

Can't start it -- multiple import errors

Open kirdin opened this issue 7 years ago • 2 comments

Hi,

thank you for your tool. I'm trying to train model, but I didn't manage to do it -- with both default and non-default configs. I'm using python 3.6 and the latest commit into master branch.

First I get

    from configurable import Configurable
ModuleNotFoundError: No module named 'configurable'

then

    from index_vocab import IndexVocab, DepVocab, HeadVocab
ModuleNotFoundError: No module named 'index_vocab'

and so on -- nn, sgd_optimizer, radam and so on.

Has anyone dealt with this?

Thank you in advance!

kirdin avatar Jan 15 '18 14:01 kirdin

Python 3 changed the relative import syntax (see here for more details).

I am using python 2.7 instead and it works.

nelson-liu avatar Feb 05 '18 06:02 nelson-liu

There is an underlying issue in that parser in this package shadows the parser found in the standard library. This makes it quite hard to use this parser as a module from other code. It could be easily addressed by renaming parser to unstableparser.

The fact that the codebase is using from __future__ import absolute_imports throughout, but not in parser/__init__.py hints at this problem and is something that should be addressed.

wwentland avatar Apr 11 '18 08:04 wwentland