how to plot the FFT of a list of values

2020-12-05 Thread Boris Dorestand
I have 16 values of the period sequence 1, 2, 4, 8, 1, 2, 4, 8, ... I compute its fourier transform using >>> from scipy import fft, ifft >>> x = [1,2,4,8,1,2,4,8] >>> fft(x) array([ 30. +0.j, 0. +0.j, -6.+12.j, 0. +0.j, -10. +0.j, 0. +0.j, -6.-12.j, 0. +0.j]) Now how can I plot

Re: how to plot the FFT of a list of values

2020-12-05 Thread Dan Stromberg
On Sat, Dec 5, 2020 at 9:20 AM Boris Dorestand wrote: > I have 16 values of the period sequence 1, 2, 4, 8, 1, 2, 4, 8, ... I > compute its fourier transform using > > >>> from scipy import fft, ifft > >>> x = [1,2,4,8,1,2,4,8] > >>> fft(x) > array([ 30. +0.j, 0. +0.j, -6.+12.j, 0. +0.j, -1

Learning tkinter - a grid problem

2020-12-05 Thread Paulo da Silva
Hi! Why this example does not work? -- from tkinter import * root=Tk() root.geometry("400x200") S=Scrollbar(root) T=Text(root) T.grid(row=0,column=0) S.grid(row=0,column=1) S.config(command=T.yview) T.config(yscrollcommand=S.set) txt="""This is a very big text - - - - - - - - - -

Re: Learning tkinter - a grid problem

2020-12-05 Thread MRAB
On 2020-12-05 18:56, Paulo da Silva wrote: Hi! Why this example does not work? There are a few bits of configuration missing: -- from tkinter import * root=Tk() root.geometry("400x200") Add: root.grid_rowconfigure(0, weight=1) root.grid_columnconfigure(0, weight=1) root.g

Re: Learning tkinter - a grid problem

2020-12-05 Thread Paulo da Silva
Às 20:20 de 05/12/20, MRAB escreveu: > On 2020-12-05 18:56, Paulo da Silva wrote: >> Hi! >> >> Why this example does not work? >> > There are a few bits of configuration missing: > >> -- >> from tkinter import * >> >> root=Tk() >> root.geometry("400x200") > > Add: > > root.grid_r

Re: how to plot the FFT of a list of values

2020-12-05 Thread Christian Gollwitzer
Am 05.12.20 um 18:16 schrieb Boris Dorestand: I have 16 values of the period sequence 1, 2, 4, 8, 1, 2, 4, 8, ... I compute its fourier transform using from scipy import fft, ifft x = [1,2,4,8,1,2,4,8] fft(x) array([ 30. +0.j, 0. +0.j, -6.+12.j, 0. +0.j, -10. +0.j, 0. +0.j, -6

Re: Bot

2020-12-05 Thread sjeik_appie
Try Selenium (preferred) or Mechanize. I recently used Selenium with Chrome for automated unittests of a web app, including a login screen. You could fire up the selenium script in a cron job at the desired time. On 1 Dec 2020 09:53, Álvaro d'Ors wrote: Hi guys, I'm new here, can

Re: Regarding Regex timeout behavior to minimize CPU consumption

2020-12-05 Thread sjeik_appie
Hi, Timeout: no idea. But check out re.compile and re.iterfind as they might speed things up. I often compile a regex once upon import, then use it in functions On 27 Nov 2020 13:33, Shahique Khan wrote: Hi Team, I have noticed if our regex sometimes does not give a resu

Re: Regarding Regex timeout behavior to minimize CPU consumption

2020-12-05 Thread Peter J. Holzer
On 2020-12-05 23:42:11 +0100, sjeik_ap...@hotmail.com wrote: >Timeout: no idea. But check out re.compile and re.iterfind as they might >speed things up. I doubt that compiling regular expressions helps the OP much. Compiled regular expressions are cached, but more importantly, if a match t