Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
I think the Ethan's suggestion about the difference between left and right channel is the answer. We hear sum and difference thanks to the Natural Binaural Technologies (unknown copyright). Two seconds of the difference with a (artificial) post-gain of 20 dB is recorded in the attached huggins-test-diff.ogg (21K). The used tool is not important, sexprs show the parameters of my test (from implementation_of_Huggins_binaural_pitch.pdf with freq 280Hz and sample rate 48kHz): (dsp! huggins-binaural-pitch (freq amp post-gain (diff-p boolean)) (with-samples ((wt (* freq *twopi-div-sr*)) (r (- 1 (* 0.03 0.5 wt))) (a1 (* -2 r (cos wt))) (a2 (* r r)) (in (white-noise amp)) (g (db->lin post-gain))) (vuglet ((ap (x) (biquad x a2 a1 1 1 a1 a2))) (maybe-expand in) (if diff-p (out (* g (- in (ap in (out in (ap in)) (bounce-to-disk ("/tmp/huggins-test.wav" :duration 30) (huggins-binaural-pitch 280 .5 0 nil)) (bounce-to-disk ("/tmp/huggins-test-diff.ogg" :duration 2 :channels 1 :header-type "ogg" :data-format "vorbis") (huggins-binaural-pitch 280 .5 20 t)) huggins-test-diff.ogg Description: Binary data ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Someone on the dsp stack exchange mentioned that you could also get this effect through additive synthesis: http://dsp.stackexchange.com/questions/31725/trouble-implementing-huggins-binaural-pitch On Sun, Jun 26, 2016 at 8:25 AM, Ethan Fennwrote: > Keep in mind that windowing (or just using a finite-length sample, which > is the same as using a rectangular window) is going to smear the FFT > spectra out, making it hard to draw any conclusion from looking at > individual bins. I'm guessing you also don't have the tail of the allpass > filter -- without that it's not strictly true that the magnitudes will be > preserved. > > Another way you could check what's going on is to subtract the two > channels. If the allpass filter is the only thing going on, you'd expect > the result to have a very narrow spectrum centered around the target > frequency. This is because the channels should be in phase at low and high > frequencies, so you should have cancellation; at the target frequency they > should be 180 degrees out of phase, so subtraction should yield > constructive interference. > > -Ethan > > > > On Sun, Jun 26, 2016 at 6:15 AM, Uli Brueggemann < > uli.brueggem...@gmail.com> wrote: > >> I listened to the example at http://www.srmathias.com/huggins-pitch/ and >> I hear the tones. >> But a deeper inspection shows that taking the differences of the >> magnitude responses after FFT results in quite big deviations, even > 10 dB. >> So it seems that the allpass delays are not really allpasses without >> influencing the magnitude response. >> >> >> 2016-06-26 3:14 GMT+02:00 Alan Wolfe : >> >>> Oh nuts. I guess my understanding of the effect was incomplete. >>> >>> I'm not using an all pass filter no, I'm just delaying the entire signal. >>> >>> Thanks you guys, I'll try with an all pass. >>> On Jun 25, 2016 4:43 PM, "Jon Boley" wrote: >>> >>> Alan, >>> >>> I'm on a phone and don't have headphones on me, so I haven't listened to >>> your examples yet. However, it sounds like you are applying a broadband >>> delay. >>> >>> Huggins pitch typically works when you apply a narrowband delay (i.e., >>> with an allpass filter). The pitch corresponds to the frequency that is >>> delayed. >>> >>> So, can you clarify - are you using an allpass filter to delay specific >>> frequencies? >>> >>> - Jon >>> >>> >>> >>> >>> On Jun 25, 2016, at 4:15 PM, Alan Wolfe wrote: >>> >>> Hey Guys, >>> >>> I'm trying to make an implementation of the Huggins Binaural Pitch >>> illusion, which is where if you play whitenoise into each ear, but offset >>> one ear by a period T that it will create the illusion of a tone of 1/T. >>> >>> Unfortunately when I try this, I don't hear any tone. >>> >>> I've found a python implementation at >>> http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know >>> python (I'm a C++ guy) and while I see that this person is doing some extra >>> filtering work and other things, it's hard to pick apart which extra work >>> may be required versus just dressing. >>> >>> Here is a 3 second wav file that I've made: >>> >>> http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav >>> >>> The first 1.5 seconds is white noise. The second half of the sound has >>> the right ear shifted forward 220 samples. The sound file has a sample rate >>> of 44100, so that 220 sample offset corresponds to a period of 0.005 >>> seconds aka 5 milliseconds aka 200hz. >>> >>> I don't hear a 200hz tone though. >>> >>> Can anyone tell me where I'm going wrong? >>> >>> The 160 line single file standalone (no libs/non standard headers etc) >>> c++ code is here: >>> http://pastebin.com/ZCd0wjW1 >>> >>> Thanks for any insight anyone can provide! >>> ___ >>> dupswapdrop: music-dsp mailing list >>> music-dsp@music.columbia.edu >>> https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >>> ___ >>> dupswapdrop: music-dsp mailing list >>> music-dsp@music.columbia.edu >>> https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >>> >>> ___ >>> dupswapdrop: music-dsp mailing list >>> music-dsp@music.columbia.edu >>> https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >> >> >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> > > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Keep in mind that windowing (or just using a finite-length sample, which is the same as using a rectangular window) is going to smear the FFT spectra out, making it hard to draw any conclusion from looking at individual bins. I'm guessing you also don't have the tail of the allpass filter -- without that it's not strictly true that the magnitudes will be preserved. Another way you could check what's going on is to subtract the two channels. If the allpass filter is the only thing going on, you'd expect the result to have a very narrow spectrum centered around the target frequency. This is because the channels should be in phase at low and high frequencies, so you should have cancellation; at the target frequency they should be 180 degrees out of phase, so subtraction should yield constructive interference. -Ethan On Sun, Jun 26, 2016 at 6:15 AM, Uli Brueggemannwrote: > I listened to the example at http://www.srmathias.com/huggins-pitch/ and > I hear the tones. > But a deeper inspection shows that taking the differences of the magnitude > responses after FFT results in quite big deviations, even > 10 dB. > So it seems that the allpass delays are not really allpasses without > influencing the magnitude response. > > > 2016-06-26 3:14 GMT+02:00 Alan Wolfe : > >> Oh nuts. I guess my understanding of the effect was incomplete. >> >> I'm not using an all pass filter no, I'm just delaying the entire signal. >> >> Thanks you guys, I'll try with an all pass. >> On Jun 25, 2016 4:43 PM, "Jon Boley" wrote: >> >> Alan, >> >> I'm on a phone and don't have headphones on me, so I haven't listened to >> your examples yet. However, it sounds like you are applying a broadband >> delay. >> >> Huggins pitch typically works when you apply a narrowband delay (i.e., >> with an allpass filter). The pitch corresponds to the frequency that is >> delayed. >> >> So, can you clarify - are you using an allpass filter to delay specific >> frequencies? >> >> - Jon >> >> >> >> >> On Jun 25, 2016, at 4:15 PM, Alan Wolfe wrote: >> >> Hey Guys, >> >> I'm trying to make an implementation of the Huggins Binaural Pitch >> illusion, which is where if you play whitenoise into each ear, but offset >> one ear by a period T that it will create the illusion of a tone of 1/T. >> >> Unfortunately when I try this, I don't hear any tone. >> >> I've found a python implementation at >> http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know >> python (I'm a C++ guy) and while I see that this person is doing some extra >> filtering work and other things, it's hard to pick apart which extra work >> may be required versus just dressing. >> >> Here is a 3 second wav file that I've made: >> >> http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav >> >> The first 1.5 seconds is white noise. The second half of the sound has >> the right ear shifted forward 220 samples. The sound file has a sample rate >> of 44100, so that 220 sample offset corresponds to a period of 0.005 >> seconds aka 5 milliseconds aka 200hz. >> >> I don't hear a 200hz tone though. >> >> Can anyone tell me where I'm going wrong? >> >> The 160 line single file standalone (no libs/non standard headers etc) >> c++ code is here: >> http://pastebin.com/ZCd0wjW1 >> >> Thanks for any insight anyone can provide! >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> >> >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> > > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
I listened to the example at http://www.srmathias.com/huggins-pitch/ and I hear the tones. But a deeper inspection shows that taking the differences of the magnitude responses after FFT results in quite big deviations, even > 10 dB. So it seems that the allpass delays are not really allpasses without influencing the magnitude response. 2016-06-26 3:14 GMT+02:00 Alan Wolfe: > Oh nuts. I guess my understanding of the effect was incomplete. > > I'm not using an all pass filter no, I'm just delaying the entire signal. > > Thanks you guys, I'll try with an all pass. > On Jun 25, 2016 4:43 PM, "Jon Boley" wrote: > > Alan, > > I'm on a phone and don't have headphones on me, so I haven't listened to > your examples yet. However, it sounds like you are applying a broadband > delay. > > Huggins pitch typically works when you apply a narrowband delay (i.e., > with an allpass filter). The pitch corresponds to the frequency that is > delayed. > > So, can you clarify - are you using an allpass filter to delay specific > frequencies? > > - Jon > > > > > On Jun 25, 2016, at 4:15 PM, Alan Wolfe wrote: > > Hey Guys, > > I'm trying to make an implementation of the Huggins Binaural Pitch > illusion, which is where if you play whitenoise into each ear, but offset > one ear by a period T that it will create the illusion of a tone of 1/T. > > Unfortunately when I try this, I don't hear any tone. > > I've found a python implementation at > http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know > python (I'm a C++ guy) and while I see that this person is doing some extra > filtering work and other things, it's hard to pick apart which extra work > may be required versus just dressing. > > Here is a 3 second wav file that I've made: > > http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav > > The first 1.5 seconds is white noise. The second half of the sound has the > right ear shifted forward 220 samples. The sound file has a sample rate of > 44100, so that 220 sample offset corresponds to a period of 0.005 seconds > aka 5 milliseconds aka 200hz. > > I don't hear a 200hz tone though. > > Can anyone tell me where I'm going wrong? > > The 160 line single file standalone (no libs/non standard headers etc) c++ > code is here: > http://pastebin.com/ZCd0wjW1 > > Thanks for any insight anyone can provide! > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Oh nuts. I guess my understanding of the effect was incomplete. I'm not using an all pass filter no, I'm just delaying the entire signal. Thanks you guys, I'll try with an all pass. On Jun 25, 2016 4:43 PM, "Jon Boley"wrote: Alan, I'm on a phone and don't have headphones on me, so I haven't listened to your examples yet. However, it sounds like you are applying a broadband delay. Huggins pitch typically works when you apply a narrowband delay (i.e., with an allpass filter). The pitch corresponds to the frequency that is delayed. So, can you clarify - are you using an allpass filter to delay specific frequencies? - Jon On Jun 25, 2016, at 4:15 PM, Alan Wolfe wrote: Hey Guys, I'm trying to make an implementation of the Huggins Binaural Pitch illusion, which is where if you play whitenoise into each ear, but offset one ear by a period T that it will create the illusion of a tone of 1/T. Unfortunately when I try this, I don't hear any tone. I've found a python implementation at http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know python (I'm a C++ guy) and while I see that this person is doing some extra filtering work and other things, it's hard to pick apart which extra work may be required versus just dressing. Here is a 3 second wav file that I've made: http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav The first 1.5 seconds is white noise. The second half of the sound has the right ear shifted forward 220 samples. The sound file has a sample rate of 44100, so that 220 sample offset corresponds to a period of 0.005 seconds aka 5 milliseconds aka 200hz. I don't hear a 200hz tone though. Can anyone tell me where I'm going wrong? The 160 line single file standalone (no libs/non standard headers etc) c++ code is here: http://pastebin.com/ZCd0wjW1 Thanks for any insight anyone can provide! ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Alan, I'm on a phone and don't have headphones on me, so I haven't listened to your examples yet. However, it sounds like you are applying a broadband delay. Huggins pitch typically works when you apply a narrowband delay (i.e., with an allpass filter). The pitch corresponds to the frequency that is delayed. So, can you clarify - are you using an allpass filter to delay specific frequencies? - Jon On Jun 25, 2016, at 4:15 PM, Alan Wolfewrote: Hey Guys, I'm trying to make an implementation of the Huggins Binaural Pitch illusion, which is where if you play whitenoise into each ear, but offset one ear by a period T that it will create the illusion of a tone of 1/T. Unfortunately when I try this, I don't hear any tone. I've found a python implementation at http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know python (I'm a C++ guy) and while I see that this person is doing some extra filtering work and other things, it's hard to pick apart which extra work may be required versus just dressing. Here is a 3 second wav file that I've made: http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav The first 1.5 seconds is white noise. The second half of the sound has the right ear shifted forward 220 samples. The sound file has a sample rate of 44100, so that 220 sample offset corresponds to a period of 0.005 seconds aka 5 milliseconds aka 200hz. I don't hear a 200hz tone though. Can anyone tell me where I'm going wrong? The 160 line single file standalone (no libs/non standard headers etc) c++ code is here: http://pastebin.com/ZCd0wjW1 Thanks for any insight anyone can provide! ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Neat, I had never heard of this illusion before. Nothing I've read mentions simply offsetting one of the channels with a delay. Rather it sounds like one of the channels should have a 180 degree phase offset in a narrow band around the target frequency, implemented via an an allpass filter. This looks like a pretty readable presentation: http://traktoria.org/files/sonar/binaural-listening/implementation_of_Huggins_binaural_pitch.pdf -Ethan On Sat, Jun 25, 2016 at 7:05 PM, Phil Burkwrote: > It sounds noisier in bursts that probably correspond to the delayed > sections. But I do not hear any tones. > > I tried trimming the bass and treble using an EQ, to mimic the other > online example but no luck. > > I'm out of ideas. > > > On Sat, Jun 25, 2016 at 3:13 PM, Alan Wolfe wrote: > >> I tried another experiment. I can "kinda" hear a tone, in that the white >> noise sounds a bit more tonal. >> >> Is this what the effect sounds like? As you point out, it does a filter, >> but it still seems like I'm not getting the actual effect. >> >> What do you think? >> >> http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise2.wav >> >> I did 16 notes. In hertz below: >> 200 >> 0 >> 400 >> 0 >> 300 >> 0 >> 800 >> 0 >> 800 >> 0 >> 300 >> 0 >> 400 >> 0 >> 200 >> 0 >> >> >> On Sat, Jun 25, 2016 at 2:43 PM, Phil Burk wrote: >> >>> Hello Alan, >>> >>> Your WAV file looks like it has the 220 sample offset. But I not hear a >>> 200 Hz tone. >>> >>> I can hear tones faintly in the example here: >>> http://www.srmathias.com/huggins-pitch/ >>> >>> 200 Hz seems like a low frequency. You might have better luck with >>> frequencies around 600 like in the Python example. >>> >>> The Python also uses a bandwidth filter to make the sound less harsh. >>> >>> Also I did not hear the tone until I noticed the melody. Try playing a >>> simple melody or scale. >>> >>> Phil Burk >>> >>> >>> On Sat, Jun 25, 2016 at 2:08 PM, Alan Wolfe >>> wrote: >>> Hey Guys, I'm trying to make an implementation of the Huggins Binaural Pitch illusion, which is where if you play whitenoise into each ear, but offset one ear by a period T that it will create the illusion of a tone of 1/T. Unfortunately when I try this, I don't hear any tone. I've found a python implementation at http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know python (I'm a C++ guy) and while I see that this person is doing some extra filtering work and other things, it's hard to pick apart which extra work may be required versus just dressing. Here is a 3 second wav file that I've made: http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav The first 1.5 seconds is white noise. The second half of the sound has the right ear shifted forward 220 samples. The sound file has a sample rate of 44100, so that 220 sample offset corresponds to a period of 0.005 seconds aka 5 milliseconds aka 200hz. I don't hear a 200hz tone though. Can anyone tell me where I'm going wrong? The 160 line single file standalone (no libs/non standard headers etc) c++ code is here: http://pastebin.com/ZCd0wjW1 Thanks for any insight anyone can provide! ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >>> >>> ___ >>> dupswapdrop: music-dsp mailing list >>> music-dsp@music.columbia.edu >>> https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >> >> > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
It sounds noisier in bursts that probably correspond to the delayed sections. But I do not hear any tones. I tried trimming the bass and treble using an EQ, to mimic the other online example but no luck. I'm out of ideas. On Sat, Jun 25, 2016 at 3:13 PM, Alan Wolfewrote: > I tried another experiment. I can "kinda" hear a tone, in that the white > noise sounds a bit more tonal. > > Is this what the effect sounds like? As you point out, it does a filter, > but it still seems like I'm not getting the actual effect. > > What do you think? > > http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise2.wav > > I did 16 notes. In hertz below: > 200 > 0 > 400 > 0 > 300 > 0 > 800 > 0 > 800 > 0 > 300 > 0 > 400 > 0 > 200 > 0 > > > On Sat, Jun 25, 2016 at 2:43 PM, Phil Burk wrote: > >> Hello Alan, >> >> Your WAV file looks like it has the 220 sample offset. But I not hear a >> 200 Hz tone. >> >> I can hear tones faintly in the example here: >> http://www.srmathias.com/huggins-pitch/ >> >> 200 Hz seems like a low frequency. You might have better luck with >> frequencies around 600 like in the Python example. >> >> The Python also uses a bandwidth filter to make the sound less harsh. >> >> Also I did not hear the tone until I noticed the melody. Try playing a >> simple melody or scale. >> >> Phil Burk >> >> >> On Sat, Jun 25, 2016 at 2:08 PM, Alan Wolfe wrote: >> >>> Hey Guys, >>> >>> I'm trying to make an implementation of the Huggins Binaural Pitch >>> illusion, which is where if you play whitenoise into each ear, but offset >>> one ear by a period T that it will create the illusion of a tone of 1/T. >>> >>> Unfortunately when I try this, I don't hear any tone. >>> >>> I've found a python implementation at >>> http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know >>> python (I'm a C++ guy) and while I see that this person is doing some extra >>> filtering work and other things, it's hard to pick apart which extra work >>> may be required versus just dressing. >>> >>> Here is a 3 second wav file that I've made: >>> >>> http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav >>> >>> The first 1.5 seconds is white noise. The second half of the sound has >>> the right ear shifted forward 220 samples. The sound file has a sample rate >>> of 44100, so that 220 sample offset corresponds to a period of 0.005 >>> seconds aka 5 milliseconds aka 200hz. >>> >>> I don't hear a 200hz tone though. >>> >>> Can anyone tell me where I'm going wrong? >>> >>> The 160 line single file standalone (no libs/non standard headers etc) >>> c++ code is here: >>> http://pastebin.com/ZCd0wjW1 >>> >>> Thanks for any insight anyone can provide! >>> >>> ___ >>> dupswapdrop: music-dsp mailing list >>> music-dsp@music.columbia.edu >>> https://lists.columbia.edu/mailman/listinfo/music-dsp >>> >> >> >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> > > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
I tried another experiment. I can "kinda" hear a tone, in that the white noise sounds a bit more tonal. Is this what the effect sounds like? As you point out, it does a filter, but it still seems like I'm not getting the actual effect. What do you think? http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise2.wav I did 16 notes. In hertz below: 200 0 400 0 300 0 800 0 800 0 300 0 400 0 200 0 On Sat, Jun 25, 2016 at 2:43 PM, Phil Burkwrote: > Hello Alan, > > Your WAV file looks like it has the 220 sample offset. But I not hear a > 200 Hz tone. > > I can hear tones faintly in the example here: > http://www.srmathias.com/huggins-pitch/ > > 200 Hz seems like a low frequency. You might have better luck with > frequencies around 600 like in the Python example. > > The Python also uses a bandwidth filter to make the sound less harsh. > > Also I did not hear the tone until I noticed the melody. Try playing a > simple melody or scale. > > Phil Burk > > > On Sat, Jun 25, 2016 at 2:08 PM, Alan Wolfe wrote: > >> Hey Guys, >> >> I'm trying to make an implementation of the Huggins Binaural Pitch >> illusion, which is where if you play whitenoise into each ear, but offset >> one ear by a period T that it will create the illusion of a tone of 1/T. >> >> Unfortunately when I try this, I don't hear any tone. >> >> I've found a python implementation at >> http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know >> python (I'm a C++ guy) and while I see that this person is doing some extra >> filtering work and other things, it's hard to pick apart which extra work >> may be required versus just dressing. >> >> Here is a 3 second wav file that I've made: >> >> http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav >> >> The first 1.5 seconds is white noise. The second half of the sound has >> the right ear shifted forward 220 samples. The sound file has a sample rate >> of 44100, so that 220 sample offset corresponds to a period of 0.005 >> seconds aka 5 milliseconds aka 200hz. >> >> I don't hear a 200hz tone though. >> >> Can anyone tell me where I'm going wrong? >> >> The 160 line single file standalone (no libs/non standard headers etc) >> c++ code is here: >> http://pastebin.com/ZCd0wjW1 >> >> Thanks for any insight anyone can provide! >> >> ___ >> dupswapdrop: music-dsp mailing list >> music-dsp@music.columbia.edu >> https://lists.columbia.edu/mailman/listinfo/music-dsp >> > > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
Re: [music-dsp] Trouble Implementing Huggins Binaural Pitch
Hello Alan, Your WAV file looks like it has the 220 sample offset. But I not hear a 200 Hz tone. I can hear tones faintly in the example here: http://www.srmathias.com/huggins-pitch/ 200 Hz seems like a low frequency. You might have better luck with frequencies around 600 like in the Python example. The Python also uses a bandwidth filter to make the sound less harsh. Also I did not hear the tone until I noticed the melody. Try playing a simple melody or scale. Phil Burk On Sat, Jun 25, 2016 at 2:08 PM, Alan Wolfewrote: > Hey Guys, > > I'm trying to make an implementation of the Huggins Binaural Pitch > illusion, which is where if you play whitenoise into each ear, but offset > one ear by a period T that it will create the illusion of a tone of 1/T. > > Unfortunately when I try this, I don't hear any tone. > > I've found a python implementation at > http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know > python (I'm a C++ guy) and while I see that this person is doing some extra > filtering work and other things, it's hard to pick apart which extra work > may be required versus just dressing. > > Here is a 3 second wav file that I've made: > > http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav > > The first 1.5 seconds is white noise. The second half of the sound has the > right ear shifted forward 220 samples. The sound file has a sample rate of > 44100, so that 220 sample offset corresponds to a period of 0.005 seconds > aka 5 milliseconds aka 200hz. > > I don't hear a 200hz tone though. > > Can anyone tell me where I'm going wrong? > > The 160 line single file standalone (no libs/non standard headers etc) c++ > code is here: > http://pastebin.com/ZCd0wjW1 > > Thanks for any insight anyone can provide! > > ___ > dupswapdrop: music-dsp mailing list > music-dsp@music.columbia.edu > https://lists.columbia.edu/mailman/listinfo/music-dsp > ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp
[music-dsp] Trouble Implementing Huggins Binaural Pitch
Hey Guys, I'm trying to make an implementation of the Huggins Binaural Pitch illusion, which is where if you play whitenoise into each ear, but offset one ear by a period T that it will create the illusion of a tone of 1/T. Unfortunately when I try this, I don't hear any tone. I've found a python implementation at http://www.srmathias.com/huggins-pitch/, but unfortunately I don't know python (I'm a C++ guy) and while I see that this person is doing some extra filtering work and other things, it's hard to pick apart which extra work may be required versus just dressing. Here is a 3 second wav file that I've made: http://blog.demofox.org/wp-content/uploads/2016/06/stereonoise.wav The first 1.5 seconds is white noise. The second half of the sound has the right ear shifted forward 220 samples. The sound file has a sample rate of 44100, so that 220 sample offset corresponds to a period of 0.005 seconds aka 5 milliseconds aka 200hz. I don't hear a 200hz tone though. Can anyone tell me where I'm going wrong? The 160 line single file standalone (no libs/non standard headers etc) c++ code is here: http://pastebin.com/ZCd0wjW1 Thanks for any insight anyone can provide! ___ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp