drowe67 / LPCNet

Experimental Neural Net speech coding for FreeDV
BSD 3-Clause "New" or "Revised" License
68 stars 25 forks source link

Tests fail #17

Closed doronbehar closed 2 years ago

doronbehar commented 4 years ago

ctest fails for me with:

Test project /build/source/build
    Start 1: core_synthesis_default
    Start 2: core_synthesis_load_20h
    Start 3: core_synthesis_mag
    Start 4: nnet2f32
1/5 Test #1: core_synthesis_default ...........***Failed    0.13 sec
Binary files birch_targ.f32 and birch.f32 differ
ERROR in synth .f32 output! Exiting...

    Start 5: SIMD_functions
2/5 Test #5: SIMD_functions ...................   Passed    0.00 sec
3/5 Test #3: core_synthesis_mag ...............***Failed    0.13 sec
logmag: 1
Binary files c01_01_mag.f32 and c01_01.f32 differ
ERROR in synth .f32 output! Exiting...

4/5 Test #4: nnet2f32 .........................   Passed    0.14 sec
5/5 Test #2: core_synthesis_load_20h ..........***Failed    0.16 sec
Binary files birch_targ.f32 and birch.f32 differ
ERROR in synth .f32 output! Exiting...

40% tests passed, 3 tests failed out of 5

Total Test time (real) =   0.18 sec

The following tests FAILED:
          1 - core_synthesis_default (Failed)
          2 - core_synthesis_load_20h (Failed)
          3 - core_synthesis_mag (Failed)
Errors while running CTest
make: *** [Makefile:130: test] Error 8

Any ideas how to debug this?

drowe67 commented 4 years ago

@doronbehar sorry I just saw this issue now. On one machine I get the same 3 tests failing - but they pass when I push and Travis runs. I'm looking into it in https://github.com/drowe67/LPCNet/pull/26

drowe67 commented 4 years ago

So I've just spent another few hours trying to debug this but haven't gotten far.

When I dig into the tests (src/diff32.c helps) I'm seeing differences in values on different machines. This could be due to a bug (like overwriting memory or uninitialised values) or small precision differences. Some of the code (e.g. around pitch doubling) is very hard to follow - fixed point code borrowed from Opus.

I don't have the time or inclination to put any more effort into this now. The tests pass on Travis and my main development machine so are useful for me when developing. This issue is documented in the project README.

hobbes1069 commented 4 years ago

Yes, the first 3 tests fail for me but the two SIMD ones pass.

doronbehar commented 4 years ago

Thanks for your effort anyway.