Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > App idea, Any idea on implementation?

Reply
Thread Tools

App idea, Any idea on implementation?

 
 
Dr Mephesto
Guest
Posts: n/a
 
      02-04-2008
Hi Guru's,

As a python newb, I was thinking about trying to implement a program
that converts whistled music into midi; the idea coming from a
proposed application in the Mydreamapp competition hosted last year,
more details here: http://stratfordisland.com/whistler/

So, does anyone have a suggestion as to the best way to implement
this? I was thinking maybe a fast fourier ever 20th of a second,
selecting the dominant frequency, and then mapping that onto a real
musical scale, then stretching or cutting the notes to a preselected
timing scheme. Is this a stupid idea? Can one do a real time fourier
transform in python? Or is there some other way to find the frequency
of a whistle easily? I want to do this in real time, so as you whistle
a tune, you see the notes appear, but if this is too hard, the
prerecorded should be also good I guess.

Im just looking for some vague opinion on how to start, so please post
any idea you might have, every thing helps! Also, If you know of any
code that already exist that might help, please post a link!

Thanks in Advance,
Dave
 
Reply With Quote
 
 
 
 
Dennis Lee Bieber
Guest
Posts: n/a
 
      02-04-2008
On Mon, 4 Feb 2008 09:28:36 -0800 (PST), Dr Mephesto
<(E-Mail Removed)> declaimed the following in comp.lang.python:

> Hi Guru's,
>
> As a python newb, I was thinking about trying to implement a program
> that converts whistled music into midi; the idea coming from a
> proposed application in the Mydreamapp competition hosted last year,
> more details here: http://stratfordisland.com/whistler/
>

<eep> It's the return of the Pitch-Rider... <G>

Something I recall was available back in the days of the Amiga; was
a small hardware box with microphone input and MIDI output... A way to
use an analog instrument (flute, guitar, etc) to generate MIDI data.

Strangely, the more powerful the computer system, the less flexible
I see MIDI becoming... Standardized instrument assignments on soundcards
and keyboards; do they still make MIDI synthesizers with full waveform
control? [I think my antique CZ-101 is still functional -- it used
digital emulation of VCO, ADSR, VCW, etc.; I seem to recall Yamaha FM
models taking over the industry]

But back to your project... If a pitch-rider could be created using
c1985 hardware, I'd think a modern computer might be able to do it...
Not sure if Python itself will be fast enough, may need C-extensions for
crunching data samples. A Google on pitchrider midi finds lots of
entries from 1992 for a $700 product...

General comment:
http://www.indiana.edu/~emusic/etext...3_MIDI11.shtml
http://www.celemony.com/cms/index.ph...dyne_audiomidi

Unfortunately, no theoretical information... Hardware versions might
have used a PLL, with an A/D conversion of the PLL control voltage into
a MIDI note number (and some software to do the note-off/note-on
message)... IE, vary the PLL control voltage until the loop oscillates
with the same dominant (probably filtered to remove harmonics) of the
input signal, then map the voltage to defined notes...


--
Wulfraed Dennis Lee Bieber KD6MOG
http://www.velocityreviews.com/forums/(E-Mail Removed) (E-Mail Removed)
HTTP://wlfraed.home.netcom.com/
(Bestiaria Support Staff: (E-Mail Removed))
HTTP://www.bestiaria.com/
 
Reply With Quote
 
 
 
 
Dr Mephesto
Guest
Posts: n/a
 
      02-04-2008
thanks for the pointers!

I just found a program that does more or less what I want, but I would
still like to have a go myself. The link is: http://www.akoff.com/music-composer.html

I gave the program a go, as there is a free trial. I found that it had
a hard time doing the conversion (or I am a really bad whistler),
maybe there is room for improvements.

So, I know it can be done, the question is, does Python have to power
to do it? And how did they actually do it anyway...



 
Reply With Quote
 
Dennis Lee Bieber
Guest
Posts: n/a
 
      02-05-2008

I'd originally gone direct email for this response (I don't have
news group posting ability from where I work, but can read via Google).

On Mon, 4 Feb 2008 13:11:04 -0800 (PST), Dr Mephesto
<(E-Mail Removed)> declaimed the following in comp.lang.python:

> thanks for the pointers!
>
> I just found a program that does more or less what I want, but I would
> still like to have a go myself. The link is: http://www.akoff.com/music-composer.html
>
> I gave the program a go, as there is a free trial. I found that it had
> a hard time doing the conversion (or I am a really bad whistler),
> maybe there is room for improvements.
>
> So, I know it can be done, the question is, does Python have to power
> to do it? And how did they actually do it anyway...
>
>


You might like to try a Google search on "pitch determination
realtime" -- since that is the difficult step; mapping a frequency to a
MIDI note and generating on/off messages on changes should be relatively
easy (unless you also want to generate pitch(bend)-wheel messages).

Or you could try to reverse engineer the BOSS TU-15. All
chromatic tuners have to do real-time pitch determination, and the TU-15
actually displays the octave (for about a 6 octave span, you won't get
the really high notes of a piano).

Some links that might be of interest:

TU-15 specs, etc.
http://www.bosscorp.co.jp/products/en/TU-15/specs.html

http://www.bosscorp.co.jp/products/e...&dsp=1&iStcd=4
An actual paper (vs all those sites that just give the citation and want
to sell the publication to you)
http://www.caip.rutgers.edu/~lrr/Rep...20detector.pdf
Another paper -- this one has code (appears to be Matlab, might be
possible to port it into NumPY/SciPY)
http://online.physics.uiuc.edu/cours...g_Wavelets.pdf

--
Wulfraed Dennis Lee Bieber KD6MOG
(E-Mail Removed) (E-Mail Removed)
HTTP://wlfraed.home.netcom.com/
(Bestiaria Support Staff: (E-Mail Removed))
HTTP://www.bestiaria.com/
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Name your fave Win app written in the last 11 years for which there IS NO cheaper or free alternative which will run on 9x-6.1, like any good 32bit app should. thanatoid Computer Support 59 10-02-2010 05:48 PM
Re: Looking for app to search for & highlight text in any app chuckcar Computer Support 0 04-27-2010 10:45 PM
Re: App idea, Any idea on implementation? Matthew_WARREN@bnpparibas.com Python 0 02-05-2008 05:50 PM
501 PIX "deny any any" "allow any any" Any Anybody? Networking Student Cisco 4 11-16-2006 10:40 PM
Nested conditional expressions ---- good idea/bad idea? nimmi_srivastav@yahoo.com C Programming 10 02-02-2005 10:51 PM



Advertisments