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

Circular import error when importing built-from-source flashinfer #248

Open
vedantroy opened this issue May 15, 2024 · 1 comment
Open

Comments

@vedantroy
Copy link

vedantroy commented May 15, 2024

Tried to compile commit 3b3ce057c935730e15da67c6879c90cbe759cbf7f from source with pip install .

When importing flashinfer, I get the error:

>>> import flashinfer
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/tmp/flashinfer/python/flashinfer/__init__.py", line 17, in <module>
    from .decode import (
  File "/tmp/flashinfer/python/flashinfer/decode.py", line 31, in <module>
    raise e
  File "/tmp/flashinfer/python/flashinfer/decode.py", line 22, in <module>
    from . import _kernels
ImportError: cannot import name '_kernels' from partially initialized module 'flashinfer' (most likely due to a circular import) (/tmp/flashinfer/python/flashinfer/__init__.py)
@vedantroy vedantroy changed the title Circular import error when importing built-from-source Circular import error when importing built-from-source flashinfer May 15, 2024
@vedantroy
Copy link
Author

The error goes away if I use:

env FLASHINFER_GROUP_SIZES=8 pip install -e .

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

1 participant