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

Unable to run Run.py #15

Open
yannis1962 opened this issue Jul 8, 2023 · 1 comment
Open

Unable to run Run.py #15

yannis1962 opened this issue Jul 8, 2023 · 1 comment
Labels
question Further information is requested

Comments

@yannis1962
Copy link

I downloaded the Zip file of the depository and launched
pip on the repository.txt
There seems to be an incompatibility between the version of scikit-learn and scipy. So finally I get the message

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for scipy
Running setup.py clean for scipy
error: subprocess-exited-with-error

× python setup.py clean did not run successfully.
│ exit code: 1
╰─> [11 lines of output]
/private/var/folders/1n/fvs3dd2d5gqghwcw8khb41_h0000gn/T/pip-install-wrqba4ts/scipy_d52b27f83b4d4bcbab2d2a119d86fdd9/setup.py:114: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
import imp

  `setup.py clean` is not supported, use one of the following instead:
  
    - `git clean -xdf` (cleans all files)
    - `git clean -Xdf` (cleans all versioned files, doesn't touch
                        files that aren't checked into the git repo)
  
  Add `--force` to your command to use it anyway if you must (unsupported).
  
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed cleaning build dir for scipy
Failed to build scikit-learn scipy
ERROR: Could not build wheels for scikit-learn, scipy, which is required to install pyproject.toml-based projects

Here is the output I get when I then run Run.py:

python Run.py

Download dataset zip file

Mange and organize files

Files extraction was successfull ...
TrainingData was created ...
TestingData was created ...
TrainingData/females was created ...
TrainingData/males was created ...
TestingData/females was created ...
TestingData/males was created ...

Train gender models

Traceback (most recent call last):
File "Code/ModelsTrainer.py", line 5, in
from sklearn.mixture import GMM
ImportError: cannot import name 'GMM' from 'sklearn.mixture' (/Users/yannis/miniconda3/lib/python3.8/site-packages/sklearn/mixture/init.py)

Identify genders

Traceback (most recent call last):
File "Code/GenderIdentifier.py", line 5, in
from FeaturesExtractor import FeaturesExtractor
File "/Users/yannis/Downloads/LIVRE/PYTHON/EXOS/01-4/Voice-based-gender-recognition-master/Code/FeaturesExtractor.py", line 4, in
from python_speech_features import mfcc
ModuleNotFoundError: No module named 'python_speech_features'

What am I doing wrong? How can I solve this problem?

@SuperKogito
Copy link
Owner

It seems that you are using newer libraries. Please make sure to use the versions specified in requirements.txt.

  • The scikit-learn and scipy issues tell me that you are not using the correct versions. The code uses older versions of scipy and scikit-learn and will probably not work with the latest versions.

  • The python_speech_features error simply means that you did not install the library.

Use a clean anaconda environment or a virtual env and install the dependencies as stated in the requirements file using pip install -r requirement.txt

@SuperKogito SuperKogito added the question Further information is requested label Jul 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants