fft

Can you compute the amplitude/power of original signal from Fourier transform?

Can you compute the amplitude/power of original signal from Fourier transform? Question: After taking the Discrete Fourier Transform of some samples with scipy.fftpack.fft() and plotting the magnitude of these I notice that it doesn’t equal the amplitude of the original signal. Is there a relationship between the two? Is there a way to compute the …

Total answers: 1

Improving FFT performance in Python

Improving FFT performance in Python Question: What is the fastest FFT implementation in Python? It seems numpy.fft and scipy.fftpack both are based on fftpack, and not FFTW. Is fftpack as fast as FFTW? What about using multithreaded FFT, or using distributed (MPI) FFT? Asked By: Charles Brunet || Source Answers: The FFTW site shows fftpack …

Total answers: 6

What is the difference between numpy.fft and scipy.fftpack?

What is the difference between numpy.fft and scipy.fftpack? Question: Is the later just a synonym of the former, or are they two different implementations of FFT? Which one is better? Asked By: Charles Brunet || Source Answers: SciPy does more: http://docs.scipy.org/doc/numpy/reference/routines.fft.html http://docs.scipy.org/doc/scipy/reference/fftpack.html# In addition, SciPy exports some of the NumPy features through its own interface, …

Total answers: 3

Recreating time series data using FFT results without using ifft

Recreating time series data using FFT results without using ifft Question: I analyzed the sunspots.dat data (below) using fft which is a classic example in this area. I obtained results from fft in real and imaginery parts. Then I tried to use these coefficients (first 20) to recreate the data following the formula for Fourier …

Total answers: 2

How to calculate a Fourier series in Numpy?

How to calculate a Fourier series in Numpy? Question: I have a periodic function of period T and would like to know how to obtain the list of the Fourier coefficients. I tried using fft module from numpy but it seems more dedicated to Fourier transforms than series. Maybe it a lack of mathematical knowledge, …

Total answers: 5

how to extract frequency associated with fft values in python

how to extract frequency associated with fft values in python Question: I used fft function in numpy which resulted in a complex array. How to get the exact frequency values? Asked By: ria || Source Answers: The frequency is just the index of the array. At index n, the frequency is 2πn / the array’s …

Total answers: 3

Python frequency detection

Python frequency detection Question: Ok what im trying to do is a kind of audio processing software that can detect a prevalent frequency an if the frequency is played for long enough (few ms) i know i got a positive match. i know i would need to use FFT or something simiral but in this …

Total answers: 4

Invertible STFT and ISTFT in Python

Invertible STFT and ISTFT in Python Question: Is there any general-purpose form of short-time Fourier transform with corresponding inverse transform built into SciPy or NumPy or whatever? There’s the pyplot specgram function in matplotlib, which calls ax.specgram(), which calls mlab.specgram(), which calls _spectral_helper(): #The checks for if y is x are so that we can …

Total answers: 11

Peak-finding algorithm for Python/SciPy

Peak-finding algorithm for Python/SciPy Question: I can write something myself by finding zero-crossings of the first derivative or something, but it seems like a common-enough function to be included in standard libraries. Anyone know of one? My particular application is a 2D array, but usually it would be used for finding peaks in FFTs, etc. …

Total answers: 10

FFT for Spectrograms in Python

FFT for Spectrograms in Python Question: How would I go about using Python to read the frequency peaks from a WAV PCM file and then be able to generate an image of it, for spectogram analysis? I’m trying to make a program that allows you to read any audio file, converting it to WAV PCM, …

Total answers: 4