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

Problem with torch #16

Open
Ppaja opened this issue Apr 10, 2021 · 2 comments
Open

Problem with torch #16

Ppaja opened this issue Apr 10, 2021 · 2 comments

Comments

@Ppaja
Copy link

Ppaja commented Apr 10, 2021

Ok so this time I installed everything for itself.
first git clone https://github.com/msieg/deep-music-visualizer.git
then cd deep-music-visualizer
then pip install tqdm
then pip install librosa
and so on, the full list of requirements.txt.

And it looks like the problem is torch. Maby this helps. Or maby the problem is somewhere else, i dont know
dmv1
dmv2

@Ppaja Ppaja changed the title Black Video Output Problem with torch Apr 10, 2021
@Ppaja
Copy link
Author

Ppaja commented Apr 10, 2021

Ok I found a solution.
With " python -m pip install torch==1.7.1 -f https://download.pytorch.org/whl/torch_stable.html" I got torch installed.

But now the next problem:
"ImportError: cannot import name 'toimage' from 'scipy.misc' (C:\Users\Niklas\AppData\Local\Programs\Python\Python39\lib\site-packages\scipy\misc_init_.py)"

Can someone help me with this?

@hubortje
Copy link

hubortje commented Apr 13, 2021

Hey there,
the scipy.misc module is deprecated. It is recommend to use the Image module of PIL instead. The function Image.fromarray() is corresponding to the scipy.misc.toimage() function.

A possible workaround is to port the original function, as explained in this stackoverflow thread.

Make sure you've imported numpy as np and image from PIL, delete the line saying from scipy.misc import toimage. Copy and paste the function code (without the first two lines where the imports are declared) and paste them in line 11 of the visualize.py.

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