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

Import Error: cannot import name 'bitpack' #189

Closed
AG89 opened this issue Jun 13, 2022 · 9 comments · May be fixed by #213
Closed

Import Error: cannot import name 'bitpack' #189

AG89 opened this issue Jun 13, 2022 · 9 comments · May be fixed by #213

Comments

@AG89
Copy link

AG89 commented Jun 13, 2022

raceback (most recent call last):
File "UVR.py", line 38, in
import inference_MDX
File "/home/cole/github/UVR-V5.21/inference_MDX.py", line 17, in
from demucs.pretrained import get_model as _gm
File "/home/cole/github/UVR-V5.21/demucs/pretrained.py", line 15, in
from .hdemucs import HDemucs
File "/home/cole/github/UVR-V5.21/demucs/hdemucs.py", line 17, in
from .demucs import DConv, rescale_module
File "/home/cole/github/UVR-V5.21/demucs/demucs.py", line 15, in
from .states import capture_init
File "/home/cole/github/UVR-V5.21/demucs/states.py", line 19, in
from diffq import DiffQuantizer, UniformQuantizer, restore_quantized_state
File "/home/cole/github/UVR-V5.21/diffq/init.py", line 22, in
from .uniform import UniformQuantizer
File "/home/cole/github/UVR-V5.21/diffq/uniform.py", line 13, in
from .base import BaseQuantizer
File "/home/cole/github/UVR-V5.21/diffq/base.py", line 21, in
from . import bitpack
ImportError: cannot import name 'bitpack' from partially initialized module 'diffq' (most likely due to a circular import) (/home/cole/github/UVR-V5.21/diffq/init.py)

got this after I updated to 5.3.0. On Linux Mint 20.2

@jorgeperezlara
Copy link

I'm also experiencing this issue on Fedora 36.

@greendrake
Copy link

+1

It looks like the code was authored on Windows as there is this binary file bitpack.cp39-win_amd64.pyd
which apparently serves the import on Windows.

The original diffq uses the module in PYX format: bitpack.pyx. Not too sure how to import it on Linux. This might be the way but I haven't tried it yet.

@greendrake
Copy link

greendrake commented Jul 16, 2022

#213 fixes it (assuming Cython is installed).

@AG89
Copy link
Author

AG89 commented Jul 19, 2022

#213 fixes it (assuming Cython is installed).

tried using the fix with cython, now I have a "No modules named 'win32api'" error. Can't seem to install pywin32 either.

@greendrake
Copy link

tried using the fix with cython, now I have a "No modules named 'win32api'" error. Can't seem to install pywin32 either.

I tested it on Linux only, so maybe it needs some further tweaking to work on Windows.

@AG89
Copy link
Author

AG89 commented Jul 19, 2022

tried using the fix with cython, now I have a "No modules named 'win32api'" error. Can't seem to install pywin32 either.

I tested it on Linux only, so maybe it needs some further tweaking to work on Windows.

I'm currently on Linux mint 20.2, so It's weird that it doesn't work.

@greendrake
Copy link

greendrake commented Jul 19, 2022

I'm currently on Linux mint 20.2

Then nothing should be requiring any sort of "*win32*" things. Guess you just need to find what tries to link them and comment out.

@AG89
Copy link
Author

AG89 commented Jul 27, 2022

I'm currently on Linux mint 20.2

Then nothing should be requiring any sort of "win32" things. Guess you just need to find what tries to link them and comment out.

Still not fixed on latest version. Maybe If you update your repo I could try it again?

@Anjok07
Copy link
Owner

Anjok07 commented Jan 2, 2023

This has been addressed. Please download the latest version of UVR.

Link:
https://github.com/Anjok07/ultimatevocalremovergui#installation

@Anjok07 Anjok07 closed this as completed Jan 2, 2023
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

Successfully merging a pull request may close this issue.

4 participants