Thanks Patrick I checked in your patch. Yes I was experimenting with 30 bit VQ codebooks recently, which is why 1200 is broken.
If you find a sample that breaks the pitch estimator or quantisation pls post it and I'll check it out. I am keeping a bunch of samples that break Codec 2 for later analysis. I test the effects of various stages by using c2sim various times with different quantisation options.: c2sim ../raw/hts1a.raw -o hts1a_uq.raw c2sim ../raw/hts1a.raw --lpc 10 -o hts1a_lpc10.raw c2sim ../raw/hts1a.raw --lpc 10 --lsp -o hts1a_lsp.raw c2sim ../raw/hts1a.raw --lpc 10 --lsp --phase0 -o hts1a_phase0.raw If it's the pitch estimator that is breaking then you will see it at the very first step above (just the basic unquantised sinusoidal model). Cheers, David On Mon, 2012-03-05 at 00:14 +0100, Patrick Strasser wrote: > Am 2012-03-02 12:06, schrieb David Rowe: > > Hello Patrick, > > > > Thanks for pointing those issues out, pls try rev 340. > > > > gecb.txt is a new joint pitch-gain VQ codebook that Jean-Marc designed. > > Will probably make 1000 bit/s possible using predictive techniques. > > Thank you very much David, r340 is building again. > > I'm playing arround to get familiar with things. I'm using a USB > headset, and listen loopbacked to my own mutterings with something like: > > arecord -r 8000 -c 1 -f s16_LE -t raw -D plughw:1,0 | tee loopback.raw | > c2enc 1500 - - | tee loopback.bit | c2dec 1500 - - | aplay -r 8000 -c 1 > -f s16_LE -t raw -D plughw:1,0 > > Notes: > * The plughw device does resampling if the hardware does not support > settings (mine does not support 8000Hz natively). > * Setting all the parameters seems to help avoiding ambiguities. My alsa > for example tries to record stereo/2 channels. > * The tee commands keep the streams for later analysis. > * I had to patch the library to get the pipes running. Some info is > printed to stdout for every frame, which was mixing up with the output > at stdout. Did not sound very well. I changed that to stderr, which > seems not to harm anything. Patch is attached. > * r340 does not work for 1200bits/s for me, the assertion for the number > of bits is triggered: > c2enc: codec2.c:858: codec2_encode_1200: Assertion `nbit == > codec2_bits_per_frame(c2)' failed. > I tracked that to the packing of the LSP bits, which are three sets of > 10 (30) bits instead of three sets of 8 (24) bits as described in the > comments. > > Anyway, 1500 and 2500 bits/s work fine, and I'm playing arround with all > kind of sounds. My wife said that high pitch wraps to very low encoded > pitch, and I noticed that in my perception the quantisation of pitch > adds much to the mechanical sound of the coding result. The pitch seems > to jump sometimes too, I'll try to pin that down more exact. > > Trying to get deeper into the guts of Codec2... > > Regards > > Patrick > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ Freetel-codec2 mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/freetel-codec2 ------------------------------------------------------------------------------ Try before you buy = See our experts in action! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-dev2 _______________________________________________ Freetel-codec2 mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/freetel-codec2
