Questions tagged [signal-processing]

AKA digital signal processing (DSP). A signal is an information-carrying changing attribute of an entity, but in the digital sense, 'signal' refers to either received or transmitted streams/blocks of data, commonly representing real-world quantities such as audio levels, luminosity, pressure etc over time or distance. 'Processing' is the act of altering, analyzing or characterizing the data to retrieve/modify information inherent in the signal in question.

A signal is an information-carrying changing attribute of an entity, but in the digital sense, 'signal' refers to either received or transmitted streams/blocks of data, commonly representing real-world quantities such as audio levels, luminosity, pressure etc over time or distance.

These real-world quantities usually comes as analogue signals that are being sampled and quantized into a digital format, i.e. a sequence or higher-dimensional array of discrete numbers.

'Processing' is the act of altering, analyzing or characterizing the data to retrieve/modify information inherent in the signal in question.

NOTE: questions not related to the programming of signal processing implementations but the signal processing theory behind are off-topic for Stack Overflow and should be posted to the appropriate sister site, Signal Processing SE.

Common topics include:

  • digital filtering;
  • audio processing;
  • image processing;
  • sampling;
  • data compression;
  • spectral analysis;

Analysis tools commonly in practice are the Discrete Fourier Transform (DFT), especially its fast implementations (FFT); and wavelet transforms.

Common softwares used in the field include ; ; , especially with /; ///; ; and various languages.

5814 questions
2
votes
1 answer

Computing the energy of a signal over 30 second periods in Python

I'm new both to Python and to signal processing, so pardon possible misuse of jargon. I have the discrete values of a signal in a Pandas dataframe x, spaced 1 second apart. It looks like this: 2017-08-02 16:42:00 0.363657 2017-08-02 16:42:01 …
Pandora
  • 203
  • 1
  • 3
  • 7
2
votes
1 answer

How extract numpy array features from spectrogram?

I created a spectrogram with this code: D = librosa.amplitude_to_db(librosa.stft(y), ref=np.max) librosa.display.specshow(D, y_axis='linear', x_axis='time') plt.colorbar(format='%+2.0f dB') plt.title('Log-frequency power…
Timebird
  • 149
  • 2
  • 4
  • 12
2
votes
1 answer

Matlab: Confusion in Discrete time filter design

I have the following code in matlab: L = 10000; PN_30dB = -100; % dBc per Hz at 10k f_offset = 5e6; f_offset2 = 10e5; F0 = 2.5e9; A = 10^0.5; Fs = 25e6; fc1 = 100; fc2 = 1e3; fc3 = 10e3; fc4 = 100e3; fc5 = 1e6; a1 = 2*pi*fc1/Fs; a2 = 2*pi*fc2/Fs; a3…
sarthak
  • 774
  • 1
  • 11
  • 27
2
votes
1 answer

Confusion in MATLAB filter roll off

I have the following code in matlab: L = 10000; Power = -100; A = 10^0.5; Fs = 25e6; fc1 = 100; fc2 = 1e3; fc3 = 10e3; fc4 = 100e3; fc5 = 1e6; a1 = 2*pi*fc1/Fs; a2 = 2*pi*fc2/Fs; a3 = 2*pi*fc3/Fs; a4 = 2*pi*fc4/Fs; a5 = 2*pi*fc5/Fs; x =…
sarthak
  • 774
  • 1
  • 11
  • 27
2
votes
0 answers

How to start sending BCCMD commands to a CSR 8675 audio chip?

I am having trouble understanding how to send BCCMD commands to a CSR 8675 audio chip For example, I would like to try out the bluecore commands described in the Audio API design document by CSR I have ADK 4.0.1 installed as well as Bluesuit 2.6,…
user13267
  • 6,871
  • 28
  • 80
  • 138
2
votes
2 answers

Help with using FFT to determine frequency of an audio sample

I'm currently developing a percussion tutorial program. The program requires that I can determine what drum is being played, to do this I was going to analyse the frequency of the drum recording and see if the frequency is within a given range. I…
2
votes
3 answers

Smoothing FFT graph in Python

I would like to smooth my FFT graphs that are obtained at 200Hz (I capture 500 points at the moment) so that the representative peaks would be shown close to THIS. This is my code: N = 500 T = 5/1000 y1 = np.array(data_Ax) yf1 =…
mcluka
  • 285
  • 1
  • 7
  • 17
2
votes
1 answer

Dimension of Filter in 3-D Convolution in MATLAB

The function to perform an N-dimensional convolution of arrays A and B in matlab is shown below: C = convn(A,B) % returns the N-dimensional convolution of arrays A and B. I am interested in a 3-D convolution with a Gaussian filter. If A is a 3 x 5…
haxtar
  • 1,962
  • 3
  • 20
  • 44
2
votes
0 answers

Continuous sound listening and matching in background on Android

I have a few sound files(not speech). I wish to run a service on an Android phone which continuously listen to the ambient sound and try to see if that sound matches with one of the sound files that I have. If a match is found I want to perform…
Abhishek Bansal
  • 5,197
  • 4
  • 40
  • 69
2
votes
0 answers

Create a signal with noise with a specific SNR using Python Numpy

I need to create a signal (a multidimensional array) and add some "additive Laplace noise" to it. Then, I want to be able to measure the SNR level of the resulting signal (in dB units). If there is an easier way, I also want to create that kind of…
2
votes
0 answers

scipy and mlab.specgram produce unexpected images

I have tried a couple of different approaches to generating a grayscale PNG of a DTFT of a video file but my results don't look anything like what other people are posting. Instead of plotting to the screen with matplotlib (as all examples tend to…
fommil
  • 5,757
  • 8
  • 41
  • 81
2
votes
1 answer

Constructing SymPy rational functions from Scipy filter design

Why aren't num_den_to_sympy(b, a) and sy.simplify(sy.expand(tf)) the same? The expanded version contains an additional s ** 4 and I don't know where it came from. import numpy as np import sympy as sy from scipy.signal import * from IPython.display…
dvc
  • 124
  • 1
  • 9
2
votes
2 answers

FFT of 50 hz signal

I have to take the FFT of a sin wave of 50 Hz and measure up to the 16 harmonics. My sampling frequency is as per Nyquist criteria: fs = 16*50*2 = 1600 Hz = 1600 samples/sec i.e in one period of 50Hz corresponds to 20 msec or 32 samples. As shown in…
Katoch
  • 2,709
  • 9
  • 51
  • 84
2
votes
2 answers

Autocorrelation code in Python produces errors (guitar pitch detection)

This link provides code for an autocorrelation-based pitch detection algorithm. I am using it to detect pitches in simple guitar melodies. In general, it produces very good results. For example, for the melody C4, C#4, D4, D#4, E4 it…
pavlos163
  • 2,730
  • 4
  • 38
  • 82
2
votes
1 answer

Harmonic product spectrum for single guitar note Python

I am trying to detect the pitch of a B3 note played with a guitar. The audio can be found here. This is the spectrogram: As you can see, it is visible that the fundamental pitch is about 250Hz which corresponds to the B3 note. It also contains a…
pavlos163
  • 2,730
  • 4
  • 38
  • 82