Open boegel opened 5 years ago
Ran into the same error ("ImportError: No module named audioproblems.test_saturationdetector") and wondering if you have any luck resolving this?
I was able to configure, compile, and install essentia version 2.1_beta5 on my macOS 10.15.4. Unfortunately it failed all three tests (./waf run_tests, ./waf run_python_tests, python3 ./waf run_python_tests).
@yyf As mentioned, I fixed that by creating an empty __init__.py
file in test/src/unittests/audioproblems/
:
touch test/src/unittests/audioproblems/__init__.py
The tests still failed though, I was hoping to hear back from the Essentia developers on this...
Hi @boegel thank you for reporting those problems.
Your patch to prevent $PYTHONPATH from being wiped looks fine to me. I think we can merge it.
On the other hand, the rest of the problems you found are related to Python 2 which we are no longer supporting.
In Python 3, the __init__.py
file is not required thanks to the implicit namespace packages.
Also, for the same reason there is no need to rename io/
as it is not imported as a separate module.
Regarding the results, those are all known issues and there should not be any problems with them.
Different architectures or dependency versions are known to produce small numeric differences that can make some Regression
or RealCase
tests fail. These differences are generally not important unless reproducing the exact values from an older Essentia version is crucial for your application. In my case, for example, I'm building Essentia from the master on Ubuntu 20.04 with Python 3.8 and all those tests are passing.
The GaiaTransform
tests are outdated and ERROR is expected.
TestLoudnessEBUR128 ERRORs because it uses float values as indices in Python 2 (round()
returns float values)
TestAudioWriter_Streaming ERRORs when writing Vorbis files. This problem is related to your particular FFmpeg installation. If you need to write audio files a quick solution would be to use any other format (.wav, .mp3...)
While running the Essentia Python tests with
python ./waf run_python_tests
, I ran into a couple of problems.Context:
-O2 -ftree-vectorize -march=native -fno-math-errno
)First, I had apply a small patch to ensure that
$PYTHONPATH
doesn't get wiped when running the Python tests (we installnumpy
in a separate location, and set$PYTHONPATH
to tell Python where to find it):Then, I had to rename
test/src/unittests/io/
totest/src/unittests/iotest/
to avoid this problem with theio.open
innumpy
getting broken (numpy 1.16.2):I also had to add a missing
__init__.py
file intest/src/unittests/audioproblems/
to fix this issue:With those fixes done, I'm able to run the Python tests, but several of them fail (see detailed output below).
Are these known issues? Are the Python tests supposed to pass? The problems I had to fix seem to suggest these tests aren't run on a regular basis?