 Real time pitch detection

I'm trying to do real time pitch detection of a users singing, but I'm running into alot of problems. I've tried lots of methods, including FFT (FFT Problem (Returns random results)) and...

How to compute ifft from fft?

I've done a fft to get fundamental frequency in real time and to implement high and low pass filters. Now I want to be able to record to a .wav file after I apply a filter. First I'll have to...

Why does negative number show up when I do FFT on a Gaussian?

I'm using this fftw library. Currently I'm trying to plot a 2D Gaussian in the form e^(-(x^2+y^2)/a^2). Here is the code: using namespace std; int main(int argc, char** argv ){ fftw_complex *in,...

1d linear convolution in ANSI C code?

Rather than reinvent the wheel, I wonder if anyone could refer me to a 1D linear convolution code snippet in ANSI C? I did a search on google and in stack overflow, but couldn't find anything in C...

Signal analysis: amplitude estimation in MATLAB

I am trying to estimate the amplitude of a signal in MATLAB: As can be seen, I can't simply take the max() and min() to get the amplitude. The signal continually wanders, and in any case isn't...

Shorten the size of time domain data

I have an impulse response of 150ms in length. But most of the signal after 30ms is close to zero. So I am assuming that their effect on the spectrum after FFT is very small. I want to shorten the...

FFTW and OpenCV's C++ interface, real and imaginary part in Mat output

I'm trying to code a FFT/IFFT function with FFTW 3.3 and OpenCV 2.1 using the C++ interface. I've seen a lot of examples using the old OpenCV formats and I did a direct conversion, but something...

what is the PSD unit by using FFT method

I'm just doing a power spectral density analysis of a signal in time domain. I'm following the fft method described in : http://www.mathworks.com/support/tech-notes/1700/1702.html It gives the...

Build VLC for iOS, get the "FFTW3 lib not found. Set FFTW3_DIR to find it." error

I want to build vlc for iOS. My environment is MacOS 10.8.3, Xcode4.6.2 with iOS6.1 SDK. I cloned the vlc lib form https://github.com/videolan/vlc.git, cd into the /extras/package/ios, and run the...

OpenCV VideoWriter using ffmpeg with "Could not open codec 'libx264'" Error

I am new to OpenCV, and I want write Mat images into video using VideoWriter on Ubuntu 12.04. But when constructing VideoWriter, errors came out. It seems that OpenCV invoke ffmpeg API using...

find RMS value in frequency domain

i would like to find RMS value in frequency domain,i used this site for help http://www.dsprelated.com/showmessage/123177/1.php but there it is calculated using FFT,but what if i am using...

Optimal value of sampling frequency for guitar notes detection

I am running FFT algorithm to detect the music note played on a guitar. The frequencies that I am interested are in the range 65.41Hz (C2) to 1864.7Hz (A#6). If I set the sampling frequency of...

how to get phase fft of a signal &-- can i get phase in time domain?

i can get magnitude of signal coming from .wav file , but how to get the phase of that signal too ,,, Here is the where i browse for .wav file and extract the signal def browse_wav(self): ...

Python numpy equivalent of bandpower() from MATLAB

I am using Python numpy's ftt.ftt() method to generate the fourier transform of a signal. However I want to calculate the bandpower over a range of frequencies. MATLAB has the method...

analyzing FFT data for mean frequency?

I used numpy fft.fft to analyze some time series data (black) and generate a plot like the following: From the FFT data (in red) i calculated mean frequency by multiplying x*y for each data point...

Generating K-space from magnitude and phase

My question might be simple but I really need to make sure that the process I am doing is valid. The MRI scanner acquires k-space data, S, and then takes 3D inverse Fourier Transform to...

While compiling, I get the following error: undefined reference to `gr::fft::window::blackman_harris(int, int) I know that this linker error is due to not having the gnuradio linker flag in my...

C# Identify blur image with FFT

I'm looking for a way to identify if an image is blur in C#. I saw this post but I did not see the way to apply to my case. I found the AForge.dll to apply the FFT to my Image. I'm looking for a...

Importing/Using p5.Sound into React

I'm trying to get p5.sound into my React app, after having successfully gotten p5.js canvas functionality working. I have a p5Wrapper for my p5 sketch. And as I said the canvas functionality...

Audio Frequencies in Python

I'm writing a code to analyse a single audio frequency sung by a voice. I need a way to analyse the frequency of the note. Currently I am using PyAudio to record the audio file, which is stored as...

How to properly scale frequency axis in Fast Fourier Transform?

I am trying some sample code taking the FFT of a simple sinusoidal function. Below is the code import numpy as np from matplotlib import pyplot as plt N = 1024 limit = 10 x = np.linspace(-limit,...

Angular spectrum method using python

I am trying to numerically propagate a given (electric) field using the angular spectrum method. For this I am following "Principles and Applications of Fourier Optics" (Robert K. Tyson) Chapter...

How to import and utilize P5.Sound in Vue?

I have been trying to make a music visualizer app using Vue and P5, and after tinkering with P5 using this article as my guide...

How do I import sklearn on python 3.5.0 without a Type error?

I installed the prerequisites to install sklearn via this page: https://scikit-learn.org/stable/install.html and everything installed fine. However, when I attempt to import sklearn I receive the...

plot numpy fft in python returns wrong plot

I am trying to use numpy fft to plot some data from a dataframe : plt.plot(np.fft.fft(df_valid_daily_activity.stepsDaily)) I get this : I don't understand why the plot is so steep in the...

Spectrogram in python using numpy

I need to make spectrogram using numpy. I take 1s of audio and split it into 0.02s chunks. Then I calculate FFT using numpy and put it back together into one image. Results are poor. Here is...

(215:Assertion failed) type == CV_32FC1 || type == CV_32FC2 || type == CV_64FC1 || type == CV_64FC2 in function 'dft'

I am trying to correct exposure in images using fourier. This is the error I am facing 5 padded = np.log(padded + 1) #so we never have log of 0 6 global complex 7 complex =...

efficiently converting for model.fit

I'm struggling in loading data into model.fit efficiently. My code creates training_data object with samples and values. Samples is a standard python list of objects of tf.Tensor class. Values is...

No name 'fft' in module 'scipy'

I tried to import FFT from SciPy and got "No name 'fft' in module 'scipy' ". Last time I checked, Scipy did have these modules, so I don't know why I'm getting this error.

How to find peaks of FFT graph using Python?

I am using Python to perform a Fast Fourier Transform on some data. I then need to extract the locations of the peaks in the transform in the form of the x-values. Right now I am using Scipy's fft...