Python is a high-level interpreted general programming language. Python has popular numerical and scientific libraries/packages, most notably numpy and scipy. The scipy.signal package is a powerful signal processing software collection. This tag covers the use of numpy, scipy, and other Python ...

learn more… | top users | synonyms

0
votes
2answers
20 views

FFT over a fixed and equal numbers

I've got a vector of $100 000$ numbers. All numbers are equal ($7000$ for example). If I perform FFT over this vector, what will I get? From my understanding, I should receive a fixed DC line. Is ...
0
votes
0answers
15 views

Synchronization of two audio tracks via Mel-frequency cepstral coefficients (MFCCs)

I am trying to solve the (common) problem of synchronizing (i.e. measuring the delay between) two audio tracks recorded from different sources during a conference talk (about 1h of audio). One track ...
0
votes
0answers
21 views

Minimum norm algorithm [on hold]

I need help with combining results from regression equation into an optimization module. There is this research paper which I read that mentions this. It's more of a signal processing thing. Can ...
-2
votes
1answer
20 views

Adaptive Piecewise Constant Approximation (APCA) with wavelets/DWT

I am trying to approximate a vector or a time series, in order to have as little changes as possible. To do so, I pretend to apply the Adaptive piecewise constant approximation (APCA) algorithm. ...
0
votes
0answers
27 views

GCC-PHAT Python

I'm implementing a GCC-PHAT function from matlab to python using this code (as the gccphat function in matlab) : ...
0
votes
0answers
19 views

How do I comparing two audio call properties using Audio Fingerprinting algorithm [closed]

I am actually doing a project on how to identify a call audio and its traversed path using audio fingerprinting. In other words, to match unlabeled audio by the stored to know the path taken by the ...
0
votes
0answers
23 views

anti aliasing filter which suppresses spectral components above half sampling frequency

I'm new to designing filters, and I have to make an anti aliassing filter (in python) in function of the subsampling factor, which suppresses spectral components above half the sampling frequency with ...
3
votes
0answers
50 views

How to remove a common noise signal from a set of signals?

I have 2D measurement results which seem to have a constant non-trivial background as shown here: For every column in this image, there seems to be a similar oscillation. I'd like to distinguish ...
0
votes
0answers
25 views

Python cv2 Image Pyramids

Trying to implement the famous Orange/Apple pyramids blending (cv2 Image Pyramids). Note: Both images shape is 307x307. However, since the result image is blurred due to clipping values in ...
0
votes
0answers
29 views

Translating Bessel filter from python to C - odd behavior past the cutoff frequency

I recently translated the code from scipy.signal.bessel to C in order to implement a bessel filter in a piece of analysis ...
0
votes
1answer
32 views

Formula for Bessel low-pass filter coefficients

When I am filtering a signal in python, it has a built in function to generate bessel filter coefficients given a cutoff ratio and a filter order (number of poles). I am trying to translate this to C ...
1
vote
2answers
120 views

Clicks at end of chirp signal

When creating a scipy chirp function I get some clicks at the start end the end. The first one is quite easy to fix using a phase difference of 90 degrees. The problem I have is that the end point is ...
0
votes
0answers
23 views

What would be a quick way to set up a resonance experiment using python? [closed]

I have done research on resonance and resonators and, for fun, I would like to build an experiment to test if I can predict the resonant frequencies of a few bottles. The major issue that I'm running ...
1
vote
0answers
37 views

how to get an input test signal for convolution/ distortion method

i am trying to do some experiments with Total Harmonic Distortion. According to ...
2
votes
1answer
103 views

Demodulating FSK audio in Python

I am trying to write a Python script that can demodulate an FSK modulated audio file and return the data encoded in the audio. The data being transmitted is GPS NMEA strings which are embedded as the ...
0
votes
1answer
23 views

Autocorrelation of a noisy linear map

I am interested in calculating the autocorrelation function of a linear map with some noise (model given below) but am slightly confused in doing so. At first, I did not realize there were two ...
0
votes
3answers
89 views

Convolution and windowing using a buffer - how do I do overlap add?

I'm reading chunks of audio signal (1024 samples) using a buffer, applying a Hanning window, doing an FFT on it, then reading an Impulse Response, doing its FFT and then multiplying the two ...
2
votes
1answer
76 views

discrete digital filtering in python

I am not from DSP background and also not sure if I am posting this in right community. I have basic understanding of resistors, capacitors and filters. My requirement is as follows- The supply ...
0
votes
2answers
28 views

Unexpected behaviour when using lfilter with initial filter delay multiple times

I want to filter a very long signal in smaller parts, therefor I am currently using scipys lfilter with an initial filter delay doing multiple iterations of: ...
0
votes
0answers
43 views

How to organize EEG data for SVM classification in python?

I am trying to classify EEG data taken from "http://archive.ics.uci.edu/ml/machine-learning-databases/eeg-mld/eeg.data.html" using python SVM. According to few researches, I found that data for ...
0
votes
0answers
122 views

How to design an interpolated notch filter in Python to filter powerline harmonics

I have a a time domain data set that records the magnetic field vs time, which must be processed to reveal an embedded signal. This data also contains power line harmonics (i.e. multiples of 60 Hz) ...
0
votes
2answers
70 views

How to identify and differentiate frequency and time in EEG data using python?

I have an EEG data of 200 Hz and sampled at 4097. I have few doubts and questions related to this data: What does it mean by sampling in EEG data? I am getting the sample rate and the frequency ...
1
vote
0answers
14 views

approach to differentiate noisy data with steep ramp

I'm trying to write some image processing code in python to differentiate between two types of images (we'll call them set Blue and set Amber). I have run an algorithm I wrote that results in the ...
4
votes
2answers
146 views

Convert sine wave signal to square wave signal

I have a signal containing a variation of digital ASK type on-off keyed sine wave among which some stochastic irrelevant harmonic waves occur, like you can see on this figure: In its current form ...
1
vote
0answers
49 views

Window function on large arays

Hello I'm reading the following document to better understand windowing and how to use it. "Spectrum and spectral density estimation by the Discrete Fourier transform (DFT), including a ...
2
votes
2answers
55 views

How to know when a sound in a given frequency starts and ends?

I need to detect two sounds (913 Hz and 1370 Hz), knowing the time in which each starts and ends. At this time, I am using a band pass filter (butter), and this is the result: Here is the first ...
0
votes
0answers
24 views

Support Vector Machine is unable to recognize the digits in images properly

I am training a SVM on MNIST Handwritten digits database to make a basic digit recognizer. It is able to recognize digits easily on some standard images I took from a source. I then captured an image ...
5
votes
2answers
280 views

Filtering a digital signal online in real-time using python

I am currently trying to apply a bandpass filter to a signal in real-time. There are samples coming in with a constant sampling rate and i would like to calculate the corresponding bandpass filtered ...
0
votes
0answers
11 views

How can I use a trained model to generate related images?

Suppose I have a data set of a large number of related images and I extract HOG features and train it using SVM Classifier or KNN Classifier. How can I use this model to generate a new image which is ...
0
votes
0answers
33 views

Image rotation - bilinear interpolation method

I am trying to rotate an image but I am getting unsuccessful results. I realise I can just use rotate functions in packages but I am trying to do this in a particular way so I can understand what is ...
0
votes
1answer
77 views

Improve coverage of BackgroundSubtractorMOG2 and findContours

I'm trying to track players on a soccer field, using a fixed camera. The picture below shows the results of BackgroundSubtractorMOG2, the second picture below the results of findContours on the ...
1
vote
2answers
77 views

Additive synthesis vs. “just draw the waveform”

I've been experimenting with PYO recently, a Python module for sound synthesis and audio processing. This is really my first foray into this topic, so I have what is probably a very basic question. ...
0
votes
0answers
160 views

FSK Demodulation in Python

I'm trying to demodulate an FSK audio file. The data are from geospatially encoded media where NMEA GPS strings were encoded to audio with 4800 baud and embedded in video. My goal is to use Python to ...
0
votes
1answer
23 views

Artificial Neural Network Preprocessing in Real-Time Applications

I've come across an issue with my ANN when attempting to port my offline analysis to an online, real-time, application. I currently train my algorithm using an array of input data, number of ...
0
votes
0answers
83 views

How to find the largest empty rectangle using OpenCV?

I need to find the coordinates of the largest empty rectangle in a PNG image. The rectangle should consist of light colors (if that is too difficult, white pixels only are fine) and should be ...
0
votes
1answer
37 views

Why do I have to divide by $\pi$ in order to scale amplitude of sine frequency spectrum?

Recently I found my old code to transform sine wave from time domain to frequency domain. Below I post simplified version of it. ...
2
votes
1answer
575 views

Python - Normalized cross-correlation to measure similarites in 2 images

I'm trying to measure per-pixel similarities in two images (same array shape and type) using Python. In many scientific papers (like this one), normalized cross-correlation is used. Here's an image ...
4
votes
1answer
37 views

How to merge transitions?

I need to represent my signal as a set of transitions from one level to another, and I am interested in transitions that have relatively big amplitude 2000+. I applied median filter to get rid of the ...
4
votes
1answer
67 views

STFT Window Size is 2048, Why is the output 1025?

I feel like I am having a brainfart over here and can't seem to remember what's going on with STFT outputs. Consider these two lines of code from the Python library Librosa: ...
0
votes
1answer
87 views

Sampling rate conversion for audio using ffmpegwrapper in python

I have many audio files @ 22kHz. I want to convert it to 44.1kHz. Since I have many files to convert, I am looking for an easy solution. I came across ffmpegwrapper for python. I installed the package ...
0
votes
1answer
99 views

Find reappearing pattern in the signal

I am working with a signal that describes energy consumption in some house as a function of time and I am trying to find time intervals that correspond to some particular type of dish washer. What do ...
0
votes
3answers
446 views

Why is convolution or FFT breaking in this case?

It is well-known that convolution in real space corresponds to multiplication in the reciprocal space. Yet, I obtain different results using both methods in the case that I'm going to present. I am ...
0
votes
1answer
73 views

Get phase information from bursty time series with amplitude variability and sharp edges

I have time series like this one, and I am trying to get the phase information from it. If it matters why, because I need to compute the precision of the cycles and amplitude variability is ...
2
votes
2answers
146 views

How to filter almost periodic noise?

I have signal that looks like this: As you can see there are some almost periodic pulses at the background with amplitude about 1000. I am saying almost, because, if you zoom in, you may see that ...
0
votes
2answers
232 views

High-pass filtering pre-processing before computing audio features

I want to compute acoustic features on a set of audio files. These features can be classical audio features as spectral flux, but also acoustic indices as proposed in the seewave R package ). I ...
0
votes
0answers
17 views

Welch's method equivalence between R (oce) and Python (scipy)

I try to port a code from R to python but I can't obtain the same result when applying the Welch method. This is the R code with the oce package: ...
1
vote
0answers
22 views

Emulate signal loss of a pixellated detector in Python?

I have a matrix 64x64 where each cell represents the pixel of a pixellated detector. The spacial response of this detector decreases by going further from its center (that is, coordinates "31,31" or ...
0
votes
0answers
161 views

Doing analysis using IQ demodulation in Python

I'm trying to doing an analysis using IQ demodulation. I'm doing this by taking a noisy signal which has a desired signal in it. The desired signal has a frequency that is almost stable, which I'm ...
0
votes
1answer
124 views

Calculating RMS/Crest Factor for a Stereo Signal

I'm doing some MIR related work with stereo audio and am a little unsure on how to proceed with some basic tasks. All my academic work prior to this has involved forcing audio to "mono" to perform ...
0
votes
0answers
59 views

What are best practices to compute an audio spectrogram?

The spectrogram if generally defined with the squared magnitude of the fft. However, in lots of implementation, it seems that people just use the magnitude without square. Moreover an audio signal is ...