有人可以通过简单的信号处理代码(音频)帮助我吗? [英] Can someone help me with a simple code for signal processing (audio) ?

查看:112
本文介绍了有人可以通过简单的信号处理代码(音频)帮助我吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的程序将要读取.wav文件,然后绘制.wav文件的频率...在图旁边,我将使用频率来计算......,因此我需要将转换为数组格式的频率,该数组的索引被声明为时间.

有人可以帮我给我代码,让它们仅获取wav文件的音高(频率).

我已经阅读了很多源代码,但是有时它变得很复杂,我只需要简单的一个...

全部..

上帝保佑你

my program is about to read a .wav file, then plot the frequenzy of the .wav file... and beside plot, i''m gonna use the frequency to calculate something... so i need to put the frequency to an array format which the index of the array is declare the time.

can someone help me got give me the code to take only the pitch (frequenzy) of the wav file.

i have read many source code, but sometimes its to complex, i just need the simple one...

thx all ..

God bless you

推荐答案

一个起点可能是研究 ^ ].
如果您很幸运并且必须处理简单的WAVE,那么实现起来就不会太困难.
A starting point might be studying the Wave File specifications[^].
If you are lucky and have to deal with simple WAVEs then the implementation won''t be too difficult.


我不知道它会对您有多大帮助,但是 [ ^ ]文章在声音方面有很好的内容.只是探索一下.

祝你好运!
I don''t know how much it will help you, but this [^]article has good content on sound. Just explore it.

Good luck !


您在说什么?没有单一频率.

阅读并尝试了解您真正想要的是什么:
http://en.wikipedia.org/wiki/Spectrogram [ http://en.wikipedia.org/wiki/Fourier_transform [ http://en.wikipedia.org/wiki/Fast_Fourier_transform [可以将信号的频率更改为音符符号的音高监视系统."

它不会更改".这是音乐音高识别的一个非常复杂的问题.它不是注释符号".这个问题会显示您有多远.从技术上来说,这是将音频识别为MIDI序列的任务.

您似乎不知道您要考虑的问题有多复杂.如果您认为即使相对简单的快速傅立叶变换也很难用代码转换,那么我无法想象您可以解决音高识别问题.

我可以告诉你一件事.我找到了一些用于音乐音高识别的免费程序,并且可以在Windows上轻松使用人声识别.尽管人的语音识别似乎要复杂得多,但我发现Microsoft引擎相当成功.即使用我的英语口音也可以很好地工作,不需要教学.

相比之下,我为音乐音高识别所做的一切都差不多,但实际上是失败了.即使是相对清晰的电子键盘声音也几乎没有被认出.乐谱的得分看起来像是一团糟,我不会轻易播放,有多个错误.我能理解现实生活中没有纯音调.音乐是大量的杂音和泛音,但不是在频率相位空间而是在时间.对于什么是音高,没有明确的定义.训练有素的人耳易于识别,不会误会您.可能的问题是,与语音识别相比,这项任务的需求不高.也许这些天您可以找到更好的东西(见下文).也许吧,但是...

要了解涉及的内容,请看这里:
http://www.eetimes.com/design/embedded/4006427/A-DSP-algorithm-for-frequency-analysis [ ^ ].

这是Java中可用的框架:
http://marf.sourceforge.net/api-dev/ [ C#中的声音可视化工具 [在C#中具有频谱图的声激活记录器 [http://en.lmgtfy.com/?q= (音频+或+音乐)+音调+识别+%22C%23%22 [ http://en.lmgtfy.com/?q=(audio+OR+music )+ pitch + recognition [
What are you talking about? There is no single frequency.

Read this and try to understand what do you really want:
http://en.wikipedia.org/wiki/Spectrogram[^],
http://en.wikipedia.org/wiki/Fourier_transform[^],
http://en.wikipedia.org/wiki/Fast_Fourier_transform[^].



Follow-up discussion:

"Pitch watch system that can change the Frequency of a signal to a note symbol."


It does not "change". This is a very complex problem of the musical pitch recognition. It''s not a "note symbol". This question along shows how far you are. This is a task of recognition of the audio into, technically speaking, a MIDI sequence.

It looks like you have no idea how complex are the issues you''re trying to thinks of. If you think that even relatively simple Fast Fourier transform is something difficult to translate in code, I cannot imaging that you can approach the problem of pitch recognition.

I can tell you one thing. I found some free programs for musical pitch recognition, and I worked with human voice recognition readily available on Windows. Even though human voice recognition seems much more complex, I found Microsoft engine quite successful; it works even with my accent in English pretty well and does not require teaching.

In contrast, all I tried for musical pitch recognition was only more or less close, but effectively failing. Even a relatively clear voice of electronic keyboard was barely recognized. The notation scores looked like a mess I would not easily play back, with multiple mistakes. I can understand it. There are no pure tones in any real-life record; music is a wealth of noises and over-tones but not in the frequency-phase space but in time. There is no clear definition of what a pitch is. You should not be mistaken by a easy of recognition by a trained human ear. Maybe the problem is that this task is not in high demand compared to speech recognition. Maybe these days you can find something much better (see below). Maybe, but…

To have an idea on what involved, look here:
http://www.eetimes.com/design/embedded/4006427/A-DSP-algorithm-for-frequency-analysis[^].

This is an available framework in Java:
http://marf.sourceforge.net/api-dev/[^].

Don''t even try to discuss that this is a different computer language. The problem itself is many orders in magnitude more complex than the barrier between computer languages.

These are the C# articles on very basic techniques of working with audio input and spectral analysis:
Sound visualizer in C#[^],
Sound Activated Recorder with Spectrogram in C#[^].

Do this go get into it some more:
http://en.lmgtfy.com/?q=(audio+OR+music)+pitch+recognition+%22C%23%22[^],

or better

http://en.lmgtfy.com/?q=(audio+OR+music)+pitch+recognition[^].

I wish you luck. You would need a lot of luck just come close to the problem.

—SA


这篇关于有人可以通过简单的信号处理代码(音频)帮助我吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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