Skip to content
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

Error compiling #1

Closed
charklewis opened this issue Jan 4, 2019 · 1 comment
Closed

Error compiling #1

charklewis opened this issue Jan 4, 2019 · 1 comment

Comments

@charklewis
Copy link

When I try to compile, it errors with the below message. I have ensure I have all decencies installed.

Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/sklearn/externals/joblib/format_stack.py", line 33, in <module>
    generate_tokens = tokenize.generate_tokens
AttributeError: module 'tokenize' has no attribute 'generate_tokens'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "./ask.py", line 1, in <module>
    from bin_questions import BinQuestion
  File "/{FILEPATH}/nlp_qa_project-master/bin_questions.py", line 1, in <module>
    from nltk.tree import Tree as Tree
  File "/usr/local/lib/python3.6/site-packages/nltk/__init__.py", line 143, in <module>
    from nltk.chunk import *
  File "/usr/local/lib/python3.6/site-packages/nltk/chunk/__init__.py", line 157, in <module>
    from nltk.chunk.api import ChunkParserI
  File "/usr/local/lib/python3.6/site-packages/nltk/chunk/api.py", line 13, in <module>
    from nltk.parse import ParserI
  File "/usr/local/lib/python3.6/site-packages/nltk/parse/__init__.py", line 100, in <module>
    from nltk.parse.transitionparser import TransitionParser
  File "/usr/local/lib/python3.6/site-packages/nltk/parse/transitionparser.py", line 22, in <module>
    from sklearn.datasets import load_svmlight_file
  File "/usr/local/lib/python3.6/site-packages/sklearn/__init__.py", line 64, in <module>
    from .base import clone
  File "/usr/local/lib/python3.6/site-packages/sklearn/base.py", line 13, in <module>
    from .utils.fixes import signature
  File "/usr/local/lib/python3.6/site-packages/sklearn/utils/__init__.py", line 14, in <module>
    from . import _joblib
  File "/usr/local/lib/python3.6/site-packages/sklearn/utils/_joblib.py", line 22, in <module>
    from ..externals import joblib
  File "/usr/local/lib/python3.6/site-packages/sklearn/externals/joblib/__init__.py", line 119, in <module>
    from .parallel import Parallel
  File "/usr/local/lib/python3.6/site-packages/sklearn/externals/joblib/parallel.py", line 24, in <module>
    from .format_stack import format_outer_frames
  File "/usr/local/lib/python3.6/site-packages/sklearn/externals/joblib/format_stack.py", line 35, in <module>
    generate_tokens = tokenize.tokenize
AttributeError: module 'tokenize' has no attribute 'tokenize'
{DEVICE}:nlp_qa_project-master {USER}$ Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/multiprocessing/__init__.py", line 16, in <module>
    from . import context
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/multiprocessing/context.py", line 3, in <module>
    import threading
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/threading.py", line 7, in <module>
    from traceback import format_exc as _format_exc
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/traceback.py", line 5, in <module>
    import linecache
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/linecache.py", line 11, in <module>
    import tokenize
  File "/{FILEPATH}/nlp_qa_project-master/tokenize.py", line 3, in <module>
    import nltk
  File "/usr/local/lib/python3.6/site-packages/nltk/__init__.py", line 129, in <module>
    from nltk.collocations import *
  File "/usr/local/lib/python3.6/site-packages/nltk/collocations.py", line 38, in <module>
    from nltk.util import ngrams
  File "/usr/local/lib/python3.6/site-packages/nltk/util.py", line 15, in <module>
    import pydoc
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/pydoc.py", line 72, in <module>
    from traceback import format_exception_only
ImportError: cannot import name 'format_exception_only'
@21han
Copy link
Owner

21han commented Jul 30, 2019

@charklewis please take a look at the most updated repository, I have cleaned up lots of junk files. Also, currently it is compatible with Python3 now.

@21han 21han closed this as completed Jul 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants