Ulrich Windl
2018-Nov-02 21:00 UTC
[opus] Antw: Re: Possible bug in Opus 1.3 (opus-tools-0.2-opus-1.3)?
Hi! Excuse the delay, but I had to deal with a corrupted NTFS file system that ate many important files on an USB stick... The FLAC version of the original is almost 6MB and it can be downloaded slowly from this time-limited link: https://sbr5vjid0jgmce4q.myfritz.net:40262/nas/filelink.lua?id=0ba5a10529a6fe7b On the meaning of a logarithmic sweep: If you use foobar2000 and the "Spectrum" you can see the bar move (once it reached 50Hz, a change request for displaying lower frequencies had been denied): It should move linearly on foobar's logarithmic scale (as indicated in the file's comment). Actually I don't know the exact definition of logarithmic in Audacity, but it seems it met my needs (using linear sweep is somewhat ridiculous for the ears). On 48kHz on Opus: I'm unsure. I thought Opus can't handle 96kHz and it downsamples automatically. Why using 96kHz in the original: AFAIK Vorbis and Opus both use frequency components to encode the file. With higher sampling frequencies in the original, I was expecting to reduce the aliasing effects for higher frequencies. On the low frequencies: It's more or less for fun, but I knew one classic record where you could hear the nearby underground pass by. Quite low frequencies, too (a slight earth quake if you want to call it so). ;-) On the two opus files: I just ran the encoder twice to make sure I did not make a mistake... Regards, Ulrich>>> Jan Stary <hans at stare.cz> 01.11.18 9.06 Uhr >>>(Please wrap your lines.) On Oct 26 01:38:34, Ulrich.Windl at rz.uni-regensburg.de wrote:> Playing with Opus 1.3 I converted a tone sweep with a sample rate of 96kHz (just for fun). Before I had converted that from WAV to FLAC, and to Vorbis without problems.Can you please post the original wav? I am not sure what Audacity means by a logarithmisch sweep. Is that a fixed number of Hertz per second (SoX calls that linear)? Or a fixed number of semitones per second (SoX calls that exponantional)? (The ogg comment says 5s=10Hz, 10s=20Hz, 15s=39Hz, 20s=78Hz, 25s=156Hz, 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s=10kHz, 60s=20kHz so it seems the frequency rises logarithmically.) $ sox -c 1 -r 96k -b 16 -n /tmp/sweep.wav synth 60 sin create 1-20 gain -3> With Opus I noticed that the file size for 48kHz and 48 kbps > compared to 96kHz Vorbis at 31kbps is about double the sizeYour opusenc line says "--bitrate 56 --vbr", so where does the 48 come from? Anyway: $ flac sweep.wav $ oggenc sweep.wav $ opusenc sweep.wav sweep.opus $ ls -l sweep.* -rw-r--r-- 1 hans wheel 2635692 Nov 1 08:49 sweep.flac -rw-r--r-- 1 hans wheel 215185 Nov 1 08:49 sweep.ogg -rw-r--r-- 1 hans wheel 660815 Nov 1 08:49 sweep.opus -rw-r--r-- 1 hans wheel 11520044 Nov 1 08:49 sweep.wav So for me it is actualy about three times the size of an ogg (and about 6% the size of the original wav). I am not sure why you are using 96kHz in the original, but doing the same with a 48kHz original wav results in -rw-r--r-- 1 hans wheel 1468106 Nov 1 08:51 sweep.flac -rw-r--r-- 1 hans wheel 113787 Nov 1 08:51 sweep.ogg -rw-r--r-- 1 hans wheel 611386 Nov 1 08:51 sweep.opus -rw-r--r-- 1 hans wheel 5760044 Nov 1 08:51 sweep.wav All of them approximately halve, but opus does not. Is that expected?> and it sounds even worse (than Vorbis) > (there is a lot of noise in the lower frequencies > when a low frequency tone is being played).Are you sure your speakers/headphones can even reproduce such low frequencies accurately? I doubt it.> Here is what opusinfo outputs: > > Processing file "D:\Work\Ulrich\Musik\Vega\Opus\Audacity\Test-Sweeps\02 Sweep (0 > -20kHz at 96kHz) log.opus"... > > New logical stream (#1, serial: 000028fd): type opus > Encoded with libopus 1.3, libopusenc 0.2.1 > User comments section follows... > ENCODER=opusenc from opus-tools 0.2-3-gf5f571b > ENCODER_OPTIONS=--bitrate 56 --vbr --comp 5 > ALBUM=Test-Sweeps > ARTIST=Audacity > COMMENT=60s logarithmic sweep (0-20kHz): 5s=10Hz, 10s=20Hz, 15s=39Hz, 20 > s=78Hz, 25s=156Hz, 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s> 10kHz, 60s=20kHz > COMMENTS=60s logarithmisch > DATE=2016 > TITLE=Sweep (0-20kHz at 96kHz) log > TRACKNUMBER=2 > Opus stream 1: > Pre-skip: 312 > Playback gain: 0 dB > Channels: 1 > Original sample rate: 96000 Hz > Packet duration: 20.0ms (max), 20.0ms (avg), 20.0ms (min) > Page duration: 1000.0ms (max), 983.9ms (avg), 20.0ms (min) > Total data length: 637535 bytes (overhead: 1.07%) > Playback length: 1m:00.000s > Average bitrate: 85 kbit/s, w/o overhead: 84.09 kbit/s > Logical stream 1 ended > > > Here is the encoding output for a manual test:Wait, so there are two opus files at play here? How exactly did you create each? Is this the 48kHz one? Post the files you are describing. Jan> C:\Program Files (x86)\foobar2000\codecs\opus-tools-0.2-opus-1.3>opusenc.exe --b > itrate 56 --vbr "D:\Work\Ulrich\Musik\Vega\FLAC\Audacity\Test-Sweeps\02 Sweep (0 > -20kHz at 96kHz) log.flac" "D:\Work\Ulrich\Musik\test.opus" > Encoding using libopus 1.3 (audio) > ----------------------------------------------------- > Input: 96 kHz, 1 channel > Output: 1 channel (1 uncoupled) > 20ms packets, 56 kbit/s VBR > Preskip: 312 > > Encoding complete > ----------------------------------------------------- > Encoded: 1 minute and 0.02 seconds > Runtime: 1 second > (60.02x realtime) > Wrote: 749625 bytes, 3001 packets, 63 pages > Bitrate: 98.9456 kbit/s (without overhead) > Instant rates: 44 to 122.4 kbit/s > (110 to 306 bytes per packet) > Overhead: 0.972% (container+metadata) >_______________________________________________ opus mailing list opus at xiph.org http://lists.xiph.org/mailman/listinfo/opus
(Please wrap your lines.)> >>> Jan Stary <hans at stare.cz> 01.11.18 9.06 Uhr >>> > (Please wrap your lines.)On Nov 02 22:00:47, Ulrich.Windl at rz.uni-regensburg.de wrote:> The FLAC version of the original is almost 6MB and it can be downloaded slowly from this time-limited link: > https://sbr5vjid0jgmce4q.myfritz.net:40262/nas/filelink.lua?id=0ba5a10529a6fe7bThanks. I saved that as file.flac, uncompressed to file.wav, and compressed that as ogg and opus as follows: $ sox file.flac file.wav $ opusenc file.wav file.opus $ oggenc file.wav $ soxi file.* Input File : 'file.flac' Channels : 1 Sample Rate : 96000 Precision : 24-bit Duration : 00:01:00.00 = 5760000 samples ~ 4500 CDDA sectors File Size : 5.95M Bit Rate : 793k Sample Encoding: 24-bit FLAC Comments : ALBUM=Test-Sweeps ARTIST=Audacity COMMENT=60s logarithmic sweep (0-20kHz): 5s=10Hz, 10s=20Hz, 15s=39Hz, 20s=78Hz, 25s=156Hz, 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s=10kHz, 60s=20kHz COMMENTS=60s logarithmisch DATE=2016 TITLE=Sweep (0-20kHz at 96kHz) log TRACKNUMBER=2 Input File : 'file.ogg' Channels : 1 Sample Rate : 96000 Precision : 16-bit Duration : 00:01:00.00 = 5760000 samples ~ 4500 CDDA sectors File Size : 218k Bit Rate : 29.1k Sample Encoding: Vorbis Input File : 'file.opus' Channels : 1 Sample Rate : 48000 Precision : 16-bit Duration : 00:01:00.00 = 2880000 samples ~ 4500 CDDA sectors File Size : 842k Bit Rate : 112k Sample Encoding: Opus Comment : 'ENCODER=opusenc from opus-tools 0.2' Input File : 'file.wav' Channels : 1 Sample Rate : 96000 Precision : 24-bit Duration : 00:01:00.00 = 5760000 samples ~ 4500 CDDA sectors File Size : 17.3M Bit Rate : 2.30M Sample Encoding: 24-bit Signed Integer PCM Total Duration of 4 files: 00:04:00.00 $ ll file.* -rw-r--r-- 1 hans wheel 5947093 Nov 4 17:17 file.flac -rw-r--r-- 1 hans wheel 218397 Nov 4 17:23 file.ogg -rw-r--r-- 1 hans wheel 842170 Nov 4 17:24 file.opus -rw-r--r-- 1 hans wheel 17280080 Nov 4 17:18 file.wav So for me the opus file is four times the size of the ogg file. Is that expected, for a frequency sweep?> On 48kHz on Opus: I'm unsure. I thought Opus can't handle 96kHz > and it downsamples automatically.Apparently it did (and also reduced the 24bit to 16bit).> Why using 96kHz in the original: AFAIK Vorbis and Opus both use > frequency components to encode the file.What frequency components are those, in a sweep from 0 to 20kHz?> With higher sampling frequencies in the original, > I was expecting to reduce the aliasing effects for higher frequencies.What higher frequencies? Jan> On Oct 26 01:38:34, Ulrich.Windl at rz.uni-regensburg.de wrote: > > Playing with Opus 1.3 I converted a tone sweep with a sample rate of 96kHz (just for fun). Before I had converted that from WAV to FLAC, and to Vorbis without problems. > > 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s=10kHz, 60s=20kHz > so it seems the frequency rises logarithmically.) > > $ sox -c 1 -r 96k -b 16 -n /tmp/sweep.wav synth 60 sin create 1-20 gain -3 > > > With Opus I noticed that the file size for 48kHz and 48 kbps > > compared to 96kHz Vorbis at 31kbps is about double the size > > Your opusenc line says "--bitrate 56 --vbr", > so where does the 48 come from? > > Anyway: > > $ flac sweep.wav > $ oggenc sweep.wav > $ opusenc sweep.wav sweep.opus > $ ls -l sweep.* > -rw-r--r-- 1 hans wheel 2635692 Nov 1 08:49 sweep.flac > -rw-r--r-- 1 hans wheel 215185 Nov 1 08:49 sweep.ogg > -rw-r--r-- 1 hans wheel 660815 Nov 1 08:49 sweep.opus > -rw-r--r-- 1 hans wheel 11520044 Nov 1 08:49 sweep.wav > > So for me it is actualy about three times the size of an ogg > (and about 6% the size of the original wav). > > I am not sure why you are using 96kHz in the original, > but doing the same with a 48kHz original wav results in > > -rw-r--r-- 1 hans wheel 1468106 Nov 1 08:51 sweep.flac > -rw-r--r-- 1 hans wheel 113787 Nov 1 08:51 sweep.ogg > -rw-r--r-- 1 hans wheel 611386 Nov 1 08:51 sweep.opus > -rw-r--r-- 1 hans wheel 5760044 Nov 1 08:51 sweep.wav > > All of them approximately halve, but opus does not. > Is that expected? > > > and it sounds even worse (than Vorbis) > > (there is a lot of noise in the lower frequencies > > when a low frequency tone is being played). > > Are you sure your speakers/headphones can even reproduce > such low frequencies accurately? I doubt it. > > > Here is what opusinfo outputs: > > > > Processing file "D:\Work\Ulrich\Musik\Vega\Opus\Audacity\Test-Sweeps\02 Sweep (0 > > -20kHz at 96kHz) log.opus"... > > > > New logical stream (#1, serial: 000028fd): type opus > > Encoded with libopus 1.3, libopusenc 0.2.1 > > User comments section follows... > > ENCODER=opusenc from opus-tools 0.2-3-gf5f571b > > ENCODER_OPTIONS=--bitrate 56 --vbr --comp 5 > > ALBUM=Test-Sweeps > > ARTIST=Audacity > > COMMENT=60s logarithmic sweep (0-20kHz): 5s=10Hz, 10s=20Hz, 15s=39Hz, 20 > > s=78Hz, 25s=156Hz, 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s> > 10kHz, 60s=20kHz > > COMMENTS=60s logarithmisch > > DATE=2016 > > TITLE=Sweep (0-20kHz at 96kHz) log > > TRACKNUMBER=2 > > Opus stream 1: > > Pre-skip: 312 > > Playback gain: 0 dB > > Channels: 1 > > Original sample rate: 96000 Hz > > Packet duration: 20.0ms (max), 20.0ms (avg), 20.0ms (min) > > Page duration: 1000.0ms (max), 983.9ms (avg), 20.0ms (min) > > Total data length: 637535 bytes (overhead: 1.07%) > > Playback length: 1m:00.000s > > Average bitrate: 85 kbit/s, w/o overhead: 84.09 kbit/s > > Logical stream 1 ended > > > > > > Here is the encoding output for a manual test: > > Wait, so there are two opus files at play here? > How exactly did you create each? Is this the 48kHz one? > Post the files you are describing. > > Jan > > > > C:\Program Files (x86)\foobar2000\codecs\opus-tools-0.2-opus-1.3>opusenc.exe --b > > itrate 56 --vbr "D:\Work\Ulrich\Musik\Vega\FLAC\Audacity\Test-Sweeps\02 Sweep (0 > > -20kHz at 96kHz) log.flac" "D:\Work\Ulrich\Musik\test.opus" > > Encoding using libopus 1.3 (audio) > > ----------------------------------------------------- > > Input: 96 kHz, 1 channel > > Output: 1 channel (1 uncoupled) > > 20ms packets, 56 kbit/s VBR > > Preskip: 312 > > > > Encoding complete > > ----------------------------------------------------- > > Encoded: 1 minute and 0.02 seconds > > Runtime: 1 second > > (60.02x realtime) > > Wrote: 749625 bytes, 3001 packets, 63 pages > > Bitrate: 98.9456 kbit/s (without overhead) > > Instant rates: 44 to 122.4 kbit/s > > (110 to 306 bytes per packet) > > Overhead: 0.972% (container+metadata) > > > > _______________________________________________ > opus mailing list > opus at xiph.org > http://lists.xiph.org/mailman/listinfo/opus >
>>> Jan Stary <hans at stare.cz> schrieb am 05.11.2018 um 11:05 in Nachricht<20181105100534.GB44329 at www.stare.cz>:> (Are we off‑list now by intention?)No, just fooled by the list defaults (some need just reply, others need reply to all)> >> Did you also try to listen at the beginning, shortly before the real tone > appears in the audible spectrum? While significantly larger, Opus had > produced significant ghost noise (much less than Vorbis did)... > > Yes. But given that these are not audible sounds, > the various codecs might use various strategies of throwing them away.No, the thing was (listening with headphones) that I hear artefacts when noting was expected to be heared, or at least something completely different was expected to be heared (the artefects were in the audible spectrum while the original was still below 20 Hz or so).> I have no solid knowledge of what e.g. Ogg vs Opus does, but I would > just throw away any frequency below, say, 15 Hz. Maybe they do/don't, > and this might be the result.Maybe. If handling them correctly with the psychoacoustic model, these should not survive anyway, I guess. In practice if you make recordings with wind, you also have such low-frequency noise, so it's not a purely artificial thing...> >> > >> >> On 48kHz on Opus: I'm unsure. I thought Opus can't handle 96kHz >> >> and it downsamples automatically. >> > >> > Apparently it did (and also reduced the 24bit to 16bit). >> > >> >> Why using 96kHz in the original: AFAIK Vorbis and Opus both use >> >> frequency components to encode the file. >> > >> > What frequency components are those, >> > in a sweep from 0 to 20kHz? >> >> The frequency component at any time should be more or less exactly one >> (THE frequency). > > Exactly. So what frequencies above 48kHz are there > to be sampled at 96kHz?None. Do we want to discuss the Nyquist theorem? (AFAIR it's for pure sinus waves and is says "at least").> >> >> With higher sampling frequencies in the original, >> >> I was expecting to reduce the aliasing effects for higher frequencies. >> > >> > What higher frequencies? >> >> If you plot a 44.1kHz sine wave > > But you stop at 20kHz.OK, Nyquist again. Maybe really look how the waveform looks like. Or are you saying Opus really ignores any extra samples at that frequencies?> >> at 16kHz or higher, > > The sample bit width has nothing to do with it.? 16kHz is a frequency, not a bit resolution.> >> it does not look much like a sine wave any more. >> So my expectation was that applying DCT on that could add >> some "ghost frequencies" that did not exist in the original. > > It would be quite sad if the processing used during compression > added frequencies ABOVE the orginal, forcing the user to upsample.Yes, but I'm afraid that's how it works. Regards, Ulrich> > Regards, > > Jan > >> >> On Oct 26 01:38:34, Ulrich.Windl at rz.uni‑regensburg.de wrote: >> >> > Playing with Opus 1.3 I converted a tone sweep with a sample rate of96kHz> >> > (just for fun). Before I had converted that from WAV to FLAC, and toVorbis> >> > without problems. >> >> >> >> 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, 50s=5kHz, 55s=10kHz, >> > 60s=20kHz >> >> so it seems the frequency rises logarithmically.) >> >> >> >> $ sox ‑c 1 ‑r 96k ‑b 16 ‑n /tmp/sweep.wav synth 60 sin create 1‑20 gain‑3>> >> >> >> > With Opus I noticed that the file size for 48kHz and 48 kbps >> >> > compared to 96kHz Vorbis at 31kbps is about double the size >> >> >> >> Your opusenc line says "‑‑bitrate 56 ‑‑vbr", >> >> so where does the 48 come from? >> >> >> >> Anyway: >> >> >> >> $ flac sweep.wav >> >> $ oggenc sweep.wav >> >> $ opusenc sweep.wav sweep.opus >> >> $ ls ‑l sweep.* >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 2635692 Nov 1 08:49 sweep.flac >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 215185 Nov 1 08:49 sweep.ogg >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 660815 Nov 1 08:49 sweep.opus >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 11520044 Nov 1 08:49 sweep.wav >> >> >> >> So for me it is actualy about three times the size of an ogg >> >> (and about 6% the size of the original wav). >> >> >> >> I am not sure why you are using 96kHz in the original, >> >> but doing the same with a 48kHz original wav results in >> >> >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 1468106 Nov 1 08:51 sweep.flac >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 113787 Nov 1 08:51 sweep.ogg >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 611386 Nov 1 08:51 sweep.opus >> >> ‑rw‑r‑‑r‑‑ 1 hans wheel 5760044 Nov 1 08:51 sweep.wav >> >> >> >> All of them approximately halve, but opus does not. >> >> Is that expected? >> >> >> >> > and it sounds even worse (than Vorbis) >> >> > (there is a lot of noise in the lower frequencies >> >> > when a low frequency tone is being played). >> >> >> >> Are you sure your speakers/headphones can even reproduce >> >> such low frequencies accurately? I doubt it. >> >> >> >> > Here is what opusinfo outputs: >> >> > >> >> > Processing file"D:\Work\Ulrich\Musik\Vega\Opus\Audacity\Test‑Sweeps\02>> > Sweep (0 >> >> > ‑20kHz at 96kHz) log.opus"... >> >> > >> >> > New logical stream (#1, serial: 000028fd): type opus >> >> > Encoded with libopus 1.3, libopusenc 0.2.1 >> >> > User comments section follows... >> >> > ENCODER=opusenc from opus‑tools 0.2‑3‑gf5f571b >> >> > ENCODER_OPTIONS=‑‑bitrate 56 ‑‑vbr ‑‑comp 5 >> >> > ALBUM=Test‑Sweeps >> >> > ARTIST=Audacity >> >> > COMMENT=60s logarithmic sweep (0‑20kHz): 5s=10Hz, 10s=20Hz, >> > 15s=39Hz, 20 >> >> > s=78Hz, 25s=156Hz, 30s=312Hz, 35s=625Hz, 40s=1.25kHz, 45s=2.5kHz, > 50s=5kHz, >> > 55s>> >> > 10kHz, 60s=20kHz >> >> > COMMENTS=60s logarithmisch >> >> > DATE=2016 >> >> > TITLE=Sweep (0‑20kHz at 96kHz) log >> >> > TRACKNUMBER=2 >> >> > Opus stream 1: >> >> > Pre‑skip: 312 >> >> > Playback gain: 0 dB >> >> > Channels: 1 >> >> > Original sample rate: 96000 Hz >> >> > Packet duration: 20.0ms (max), 20.0ms (avg), 20.0ms(min)>> >> > Page duration: 1000.0ms (max), 983.9ms (avg), 20.0ms(min)>> >> > Total data length: 637535 bytes (overhead: 1.07%) >> >> > Playback length: 1m:00.000s >> >> > Average bitrate: 85 kbit/s, w/o overhead: 84.09 kbit/s >> >> > Logical stream 1 ended >> >> > >> >> > >> >> > Here is the encoding output for a manual test: >> >> >> >> Wait, so there are two opus files at play here? >> >> How exactly did you create each? Is this the 48kHz one? >> >> Post the files you are describing. >> >> >> >> Jan >> >> >> >> >> >> > C:\Program Files(x86)\foobar2000\codecs\opus‑tools‑0.2‑opus‑1.3>opusenc.exe>> > ‑‑b >> >> > itrate 56 ‑‑vbr"D:\Work\Ulrich\Musik\Vega\FLAC\Audacity\Test‑Sweeps\02>> > Sweep (0 >> >> > ‑20kHz at 96kHz) log.flac" "D:\Work\Ulrich\Musik\test.opus" >> >> > Encoding using libopus 1.3 (audio) >> >> > ‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑ >> >> > Input: 96 kHz, 1 channel >> >> > Output: 1 channel (1 uncoupled) >> >> > 20ms packets, 56 kbit/s VBR >> >> > Preskip: 312 >> >> > >> >> > Encoding complete >> >> > ‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑‑ >> >> > Encoded: 1 minute and 0.02 seconds >> >> > Runtime: 1 second >> >> > (60.02x realtime) >> >> > Wrote: 749625 bytes, 3001 packets, 63 pages >> >> > Bitrate: 98.9456 kbit/s (without overhead) >> >> > Instant rates: 44 to 122.4 kbit/s >> >> > (110 to 306 bytes per packet) >> >> > Overhead: 0.972% (container+metadata) >> >> > >> >> >> >> _______________________________________________ >> >> opus mailing list >> >> opus at xiph.org >> >> http://lists.xiph.org/mailman/listinfo/opus >> >> >> > _______________________________________________ >> > opus mailing list >> > opus at xiph.org >> > http://lists.xiph.org/mailman/listinfo/opus >> >> >>
On Nov 05 11:16:54, Ulrich.Windl at rz.uni-regensburg.de wrote:> >> >> Why using 96kHz in the original: AFAIK Vorbis and Opus both use > >> >> frequency components to encode the file. > >> > > >> > What frequency components are those, > >> > in a sweep from 0 to 20kHz? > >> > >> The frequency component at any time should be more or less exactly one > >> (THE frequency). > > > > Exactly. So what frequencies above 48kHz are there > > to be sampled at 96kHz? > > None. Do we want to discuss the Nyquist theorem?I meant what frequencise _in_your_signal_. Your signal does not contain anything above 20kHz, so why use a 96kHz sample rate?> (AFAIR it's for pure sinusNo.> waves and is says "at least"). > > > > >> >> With higher sampling frequencies in the original, > >> >> I was expecting to reduce the aliasing effects for higher frequencies. > >> > > >> > What higher frequencies? > >> > >> If you plot a 44.1kHz sine wave > > > > But you stop at 20kHz. > > OK, Nyquist again. Maybe really look how the waveform looks like. Or are you > saying Opus really ignores any extra samples at that frequencies?At what frequencies?> > > >> at 16kHz or higher, > > > > The sample bit width has nothing to do with it. > > ? 16kHz is a frequency, not a bit resolution.Ah, sorry, I mis-read. Anyway: a sample rate of 44.1kHz is enough to completely capture a signal which does not contain frequencies above 22 kHz. Like your signal doesn't.> > > >> it does not look much like a sine wave any more. > >> So my expectation was that applying DCT on that could add > >> some "ghost frequencies" that did not exist in the original. > > > > It would be quite sad if the processing used during compression > > added frequencies ABOVE the orginal, forcing the user to upsample. > > Yes, but I'm afraid that's how it works.I very much doubt that, but someone more knowledgeable about the actual Opus compression would have to step in here. Jan
On Nov 05 11:05:34, hans at stare.cz wrote:> > Did you also try to listen at the beginning, shortly before the real tone appears in the audible spectrum? While significantly larger, Opus had produced significant ghost noise (much less than Vorbis did)... > > Yes. But given that these are not audible sounds, > the various codecs might use various strategies of throwing them away. > I have no solid knowledge of what e.g. Ogg vs Opus does, but I would > just throw away any frequency below, say, 15 Hz. Maybe they do/don't, > and this might be the result.Have you also tried creating a swepp only up to those frequencies? Say, 1 to 20 Hz? Is the low-freq noise still there? Jan
Ulrich Windl
2018-Nov-05 10:41 UTC
[opus] Antw: Re: Antw: Re: Antw: Re: Possible bug in Opus 1.3
>>> Jan Stary <hans at stare.cz> schrieb am 05.11.2018 um 11:32 in Nachricht<20181105103249.GA74867 at www.stare.cz>:> On Nov 05 11:05:34, hans at stare.cz wrote: >> > Did you also try to listen at the beginning, shortly before the real tone > appears in the audible spectrum? While significantly larger, Opus had > produced significant ghost noise (much less than Vorbis did)... >> >> Yes. But given that these are not audible sounds, >> the various codecs might use various strategies of throwing them away. >> I have no solid knowledge of what e.g. Ogg vs Opus does, but I would >> just throw away any frequency below, say, 15 Hz. Maybe they do/don't, >> and this might be the result. > > Have you also tried creating a swepp only up to those frequencies? > Say, 1 to 20 Hz? Is the low-freq noise still there?Not yet; as I said the starting frequency was mainly because of the cleaner mathematics regarding the logarithmic frequency sweep...> > Jan > > _______________________________________________ > opus mailing list > opus at xiph.org > http://lists.xiph.org/mailman/listinfo/opus
On Nov 05 11:32:49, hans at stare.cz wrote:> On Nov 05 11:05:34, hans at stare.cz wrote: > > > Did you also try to listen at the beginning, shortly before the real tone appears in the audible spectrum? While significantly larger, Opus had produced significant ghost noise (much less than Vorbis did)...I experience the "same" low level noise even in a wav file, even on frequencies a bit higher, when playing on shitty enough speakers. I don't think it is a relict of the compression (it cannot be, here). Every speaker (or headphones) is designed for a certain frequency range. Outside of that range, all bets are off. I wouldn't bother with what you "hear" outside of the audible spectrum. My current bet is that the very low frequencies are correctly represented in the Opus file, but your speaker/headphones are not capable to play them properly (which is no wonder). Jan> > Yes. But given that these are not audible sounds, > > the various codecs might use various strategies of throwing them away. > > I have no solid knowledge of what e.g. Ogg vs Opus does, but I would > > just throw away any frequency below, say, 15 Hz. Maybe they do/don't, > > and this might be the result. > > Have you also tried creating a swepp only up to those frequencies? > Say, 1 to 20 Hz? Is the low-freq noise still there? > > Jan >