使用编程在音频文件中重新创建笔记 [英] Recreating Notes in an audio file using Programming

查看:50
本文介绍了使用编程在音频文件中重新创建笔记的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我有一个关于创建应用程序的问题,该应用程序会将音乐音频文件中的旋律映射到音符,例如(C,D,E,...).

问题是这样的,大多数情况下,当您学会弹奏某种乐器时,都希望听到某种歌曲或曲调,并尝试在乐器上弹奏该歌曲.

为此,您需要训练您的耳朵以识别正在演奏的音符.但这需要数小时的练习和耐心.
我要寻找的是如何编写一个程序,该程序将记录一个已录制的音频文件,并相应地产生正在该文件中播放的音符.

这就是我在想什么
1.一个人可以采样音频
2.计算信号的FFT
3.执行时间VS频率分析,以便我们知道在特定时间演奏了哪个音符
4.最后将频率转换为音符表示.

因此,如何使用C#做到这一点呢?还是有更好的方法来实现这一点?如果您可以将我定向到可能有用的链接,我将不胜感激!

欢呼

heleiance

Hey guys,

I have this question about creating an application that would map the melodies in a music audio file to notes such as (C,D,E,...).

The problem is like this, mostly when you learn to play a certain musical instrument you are expected to hear a certain song or tune and you try to play that song on your instrument.

To achieve this you need to train your ears to recognize the notes being played; but this takes hours of practice and patience.
What i am looking for is how can one write a program that would take a recorded audio file and produce the notes being played in the file accordingly.

Here is what i am thinking
1.one can take samples of the audio
2.Compute the FFT of the signal
3.Perform time Vs frequency analysis so that we can know which note was played at a particular time
4.And finally convert the frequencies to musical notes representation.

So how can one do this using C# or is there a better approach to achieving this; if you can direct me to links which might be helpful i will be most grateful!

cheers

heleiance

推荐答案

这是一个相当困难的项目,因为现实生活中乐器的声音频谱通常充满噪声和主音(如果浮动).因此,这将不仅仅是频率分析",而是真正的图像识别任务,很难解决.我对现有的音乐应用程序非常熟悉:在我所知道的所有产品中,识别质量都非常差(我的适度音乐听觉效果要好几个数量级:-).最大的问题之一是在相对较短的时间内频谱快速变化.

在诸如FFT这样的独立组件上有很多不错的作品(这并不是最难的部分),例如: http://www.extremeoptimization.com/solutions/FastFourierTransformsFft.aspx [ ^ ].我也知道CodeProject的简短文章:如何实现FFT算法 [
This is quite a difficult project, because usually the spectrum of the voice of real-life instrument is full of noise and main tone if floating. So, it will not be just "frequency analysis", it will be real image recognition task, pretty hard to solve. I''m familiar with existing musical applications doing that: the quality of recognition is quite poor in all products I know (my very modest musical hearing is orders of magnitude better :-)). One of the biggest problems is the fast change in spectrum in comparably short periods of time.

There are a number of good works on separate components like FFT (which in not the hardest part), such as this: http://www.extremeoptimization.com/solutions/FastFourierTransformsFft.aspx[^]. I also know a short CodeProject article: How to implement the FFT algorithm[^].

So idea is generally good, but — no offence — I''m quite a bit skeptical about your prospect to make a big success.

—SA


这篇关于使用编程在音频文件中重新创建笔记的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆