Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [python]

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 ...

0
votes
0answers
7 views

Show and Tell: Lessons learned from the 2015 MSCOCO Image Captioning Challenge

I am looking through the source code of this paper in tensorflow.There are two phrases of training the parameters.I want to know why two phrases?
0
votes
0answers
21 views

Realistic data technical analysis [on hold]

Suppose that I have some data like this: How can I algorithmically identify marked parts. Please guide me about some best practice(s) to identify marked parts (where the pattern changes somehow) ...
0
votes
0answers
18 views

Butterworth filters and power spectral density

I am trying to get power spectral density estimates of an hour time series, sampled at 1Hz. The only frequencies that I am interested are between 1-20 mHz. I was wondering which is the more accurate ...
0
votes
2answers
56 views

Comparing FFT for increasing time intervals in a signal

Assume a dataset where the rows represent signals: each signal $s$ is sampled at a sampling rate $f_s$ and available as an array of common length $T$. For an increasing sequence of integer times $t_i &...
0
votes
1answer
46 views

How can I modify a sound signal based on it's MFCC

I'm working on an NN algorithm with which I want to filter noise from sound signals. I have some clean speech sound samples and noise samples, by combining them I get the signal that I want to filter....
0
votes
1answer
46 views

Unit Step Response of an Integrator

Desinging a very basic 1st order integrator with the continous transfer function: $H(s) = -1 / (0.001 s)$ [No zeros, one pole at origin] I was expecting the unit step response to be positive-slope. ...
1
vote
0answers
16 views

How to envelope a non periodic Impulse signal?

I want to analyse a trc oscilloscope file, find impulses and envelope them. In the end I want to plot the envelope. data file (trc): https://ufile.io/z4m4d Code: (Python) ...
0
votes
0answers
23 views

Implementing FFT in Python without FFT package [closed]

I currently have a Python function that can perform the FFT of a set of data from a csv file, and I want to plot the frequency spectrum generated. It is for a class project, and I am unable to use any ...
1
vote
1answer
49 views

Extreme quantization of audio

I would like to take an audio sample and reduce it to a very limited set of numbers, with one value for amplitude and another for length. Example: I want to find the dimensions of the red boxes, ...
0
votes
0answers
14 views

Determine the onset’s in an audio file

I want to determine the onset’s in my audio file which means determine all the frequencies and the corresponding notes present in my audio file. Please help me with an approach in python to achieve ...
-1
votes
0answers
14 views

Confusion about spectrogram of frequency modulated signal

I'm trying to generate a signal which is frequency modulated with a sinus, between f0 and f1. Now, I have generate the signal and plotted the spectrogram, but the frequency modulation looks wierd (i.e....
0
votes
0answers
7 views

Librosa onset detection detecting too many onsets

So I was trying to use librosa's onset detect function to detect onsets. But on trying it out, this function is returning a lot more onsets than there should be for my audio file. I've included my ...
0
votes
0answers
48 views

Discrete Fourier Transform: Can't get the correct amplitude in frequency domain

I've gone through this link. I've generated a signal using two sine waves, one with an amplitude of 1000 and with a frequency of ...
0
votes
0answers
14 views

How to find a particular shape in an image?

I have a binary image and I want to search a particular shape in it. Like for eg: search for a shape like 'M' in the image. On looking up, I realized that the above task can be accomplished by hit and ...
2
votes
1answer
110 views

Calculating the first derivative of an image using DFT

I need to calculate the first derivative of a greyscale image (a 2D array) using a DFT function I built (which works). Unfortunately, the results don't seem to be correct. In the fourier domain, the ...
0
votes
1answer
58 views

Fourier Transform of ECG signal in Python

I have an ECG signal which I am analyzing using Python, as opposed to the mainstream MATLAB. So, I have digital form ECG in .dat file with .hea (header file). Below is the Fourier transform The ...
-1
votes
1answer
26 views

“Side Lobes” When Using a Butterworth filter

So I am attempting to filter a signal containing frequencies at 7Hz, 11Hz, and 74Hz. The signal lasts for 30s and looks like this between -1s and 1s: Using a butterworth filter of order 2 with lowcut=...
0
votes
0answers
10 views

Otsu Segmentation [duplicate]

I tried to do Otsu Segmentation on this Image But I get this following Result I want to segment that first picture using Otsu Method,so what I want to achieve is the "purple cell" in the center.
0
votes
0answers
38 views

How to remove ICA components from EEG?

I am doing my masters thesis on the analysis of EEG signals for various applications. Currently, I am doing the signal processing of the EEG data that I acquired using ICA method. I am using OpenBCI 8 ...
0
votes
1answer
78 views

Write a 440 Hz Sine Wave to .wav-File using Python and SciPy [closed]

This is my first post on DSP.SE! I'm a student in Computer Sciences and am just getting started with Signals and Systems, thus getting in touch with discrete signals and analyzing them. I wanted to ...
4
votes
2answers
49 views

references for techniques to reduce recursive filter startup transients

I am trying to track down references (published articles or reports ideally) that establish the basis for some of the techniques being used to minimize the effect of recursive digital filter startup ...
0
votes
0answers
69 views

Fourier Transform applied on time series data

I am willing to apply Fourier transform on a time series data to convert data into frequency domain. I am not sure if the method I've used to apply Fourier Transform is correct or not? Following is ...
0
votes
0answers
11 views

Interpreting the ICA plot when compared to PCA plot

I understand what ICA does at a high level but in the cocktail party problem context. All the examples, articles I have read take a similar problem to explain ICA where the aim is to derive the ...
1
vote
0answers
37 views

Frequency bins too powerful at the start and at the end of each sample computed DFT data

I've taken the following link http://coding-geek.com/how-shazam-works/#comments as a project to start practising and learning signal processing and python programming for me to get started in speech ...
1
vote
1answer
86 views

Red Blood Cell Color Image Segmentation

I want to segment this Red Blood Cell Image on HSI color space.I want to try the Otsu Method but from what I read that method work only on Grayscale image.Do you have any suggestion for suitable image ...
0
votes
2answers
61 views

Shifting signal smaller than discrete step

I have a image that I need to shift with less than a pixel. My plan was to do a Fourier transform and multiply the signal with $e^{-aiu-biv}$ where $a, b$ are the shifts in x and y direction. This ...
0
votes
0answers
15 views

Readjusting the LSB encoded pixels in Edge Adaptive Steganography

I have two pixels generated using LSB encoding $(x_{i}^{'}, x_{i+1}^{'})$. However, there are chances that either one of them, or both, lie outside the range $[0, 255]$ or $|x_{i}^{'} - x_{i+1}^{'}| &...
0
votes
1answer
39 views

Resampling from variable to fixed-rate [closed]

I have a gyroscope which reports x,y,z values to my embedded device. The rate that one sample appears is variable and has a jitter of around 10ms. However I later want to have a log file with a fixed ...
1
vote
1answer
69 views

Sound Source Location

I have four microphones which I want to use to locate the direction of an audio source. Is there any Python module that implements an algorithm that, given the recordings of the four microphones, will ...
1
vote
2answers
71 views

Why is my DFT/FFT always 90° out of phase?

I'm doing an FFT using Python and Numpy on one machine, and C# on another. I'm using some dummy data that mimics how I'll eventually be gathering data from sensors in the C#/UWP application. The two ...
1
vote
1answer
67 views

Finding audio “tics” in stereo wav files using python

I have thousands of audio files that I want to "batch" process searching for audio tics. This is easily done using a DAW but that requires opening each file independently, searching for the tic (...
0
votes
0answers
7 views

what's gray level features and how to compute it with python

Hi I am a new one to computer vision. now I am trying to classify the image into good or bad based on image features. Now I want to use the features in the following paper: https://arxiv.org/pdf/1202....
1
vote
0answers
90 views

real refractive index from Kramers Kronig relation

I have a measurement of the complex part of the refractive index $k$ (where the refractive index is $m = n + i\,k$) measured at a nonlinear grid of wavelengths or frequencies that span several orders ...
1
vote
2answers
71 views

Simple way to determine square-ness of signal?

Not entirely sure if my term is correct. Feel free to edit title. I have a lot of time series, where the data quality is determined by how linear each sub-sequence is. It doesn't matter if it jumps ...
1
vote
1answer
212 views

How to remove ECG artifacts from EMG data?

I'm new to signal processing and try to analyze EMG data from pectoralis major and other respiratory muscles. Unfortunately, there are strong ECG artifacts in all recordings and I don't know how to ...
0
votes
0answers
68 views

How do I smooth a binary signal in Python?

I have a signal that is binary (a sequence of 1's and 0's). I want to be able to "smooth" the signal; that is, I want to transform the signal such that in regions where there are 0's, the signal will ...
0
votes
1answer
37 views

Time-domain LPF not showing expected behavior

I am trying to implement a simple first-order Butterworth Low-Pass filter in Python. I have some code that makes use of scipy.signal.butter and scipy.signal.filtfilt. It works fine, but I wanted to ...
0
votes
0answers
13 views

Cut two signals from a correlated signal

I have the following situation, I did ACF auto correlation between temperature and strain. I got a shifted signal in temperature and I already shifted it. Of course the shifted signal has shorter ...
2
votes
2answers
48 views

How do MATLAB and/or Python treat $2^n$ samples rule in FFT

As far as I have read, an FFT requires that the number of original data points must be a power of 2. I'm wondering whether the tools like MATLAB or Python which have FFT functions take care of this ...
1
vote
1answer
1k views

Removing noisy lines from image - opencv - python

I want to process different type of image to extract actual text from noisy image .I am using open cv to do this job it is working fine but the problem is I need to set different lower threshold to ...
1
vote
1answer
63 views

zero padding shifting signal peak?

I am trying to find the fundamental frequency of a low-frequency signal. I need an estimate that is precise to .01 Hz based on only a few cycles, so I'm trying to code up a fft in Python. The signal ...
1
vote
1answer
40 views

Time signal FFT different for whole signal than half signal on high frequencies

I have a time signal of u from 0 to 1000 time units. If I chop the signal in two halves and compare the frequency spectrum of both it looks similar, as it should (...
0
votes
0answers
26 views

What are the best resources to learn feature extraction and classification of signal?

First of all, forgive me if I am posting anything wrong; I am new here. I need to learn signal processing like feature extraction and classification for my final year thesis. I asked some persons and ...
1
vote
0answers
96 views

Remove a line in image with FFT

I would like to remove vertical line from an image (an example). I took a 2D FFT and try to apply a mask to suppress the line. Nonethelesse the approch is not very efficient, because i lose an ...
1
vote
1answer
59 views

Reconstruction of a signal from non-uniform samples [duplicate]

So I'm having some troubles with a signal that's been sampled but where the samples don't have consistent intervals. I've been looking into the NFFT (in python) as a starting point but I'm a complete ...
0
votes
1answer
120 views

Is there a way to obtain the transfer function from a bode plot on Python? (I know that it is possible on Matlab)

Quite simply, I have a bode plot obtained from a source signal. Now I wish to obtain the transfer function. I know it is possible with Matlab: http://www.mathworks.com/help/ident/examples/frequency-...
1
vote
2answers
80 views

wrong output using numpy fft on a tone

I am getting the wrong output with the following simple implementation of Python fft. Can someone please explain what I need to fix? ...
3
votes
1answer
137 views

Finding a signal inside another signal

I have a 1D array of 32 bit floating point numbers representing the current draw of a radio operating over a 40 minute span. The number of elements in the array is 29 million and change. There is a ...
0
votes
1answer
80 views

signal reconstruction [closed]

I'm new to DSP so the question might seem a little bit stupid: When using a low pass filter (say Butterworth filter) with Python, I came across an algorithm with which I can reconstruct my signal ...
0
votes
2answers
31 views

Window length in matplotlib's specgram

In the paper about speaker verification I can read that Two quantities have to be set: the length of the window and the shift between two consecutive windows. For the length of the window, two ...