Skip to content

Instantly share code, notes, and snippets.

View ahota's full-sized avatar
🤖
Beep boop

Alok ahota

🤖
Beep boop
  • Intel
View GitHub Profile
@matiasmorant
matiasmorant / pythonOneLiner.py
Last active July 30, 2021 01:02
Amazing Python One-Liner
This file has been truncated, but you can view the full file.
exec(''.join(chr(int(''.join(str(ord(i)-8203)for i in c),2))for c in '​​​‌​‌​‍‌‌‌​​‌‌‍‌‌​‌‌‌‌‍‌‌​‌‌‌​‍‌‌​​‌‌‌‍​‌‌‌‌​‌‍‌‌​​​‌​‍​‌​​‌‌‌‍‌​‌​​‌‌‍‌​‌​‌​‌‍‌​‌​​​‌‍‌‌‌‌​‌​‍‌​​​​​‌‍‌‌‌​‌‌‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​‌​​​​‍‌​​​‌‌​‍‌​‌​​‌​‍‌​‌‌​‌​‍‌​‌​​‌​‍‌​‌​‌‌​‍‌​​‌​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​‌‌​‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​‌‌​‌‍‌‌​‌​‌​‍‌​​​​​‌‍‌‌‌‌​​​‍‌​​‌‌‌‌‍‌​‌​‌‌​‍‌​‌​​‌​‍‌​​​‌‌​‍‌​‌​‌​​‍‌‌​‌​‌‌‍‌​​‌‌​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​‌​‌‌​‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​‌​‌​​‍‌​​​‌​‌‍‌​​​‌‌​‍‌​​‌‌‌​‍‌​‌​​‌​‍‌​‌​​‌‌‍‌​​​​‌​‍‌‌‌​​​​‍‌‌​​​‌​‍‌‌​‌​​‌‍‌​​​​‌​‍‌​​​‌‌‌‍‌​‌​‌​​‍‌​​​​‌‌‍‌​​​​‌​‍‌​‌​‌​​‍‌‌​​‌​​‍‌​​‌​​​‍‌​‌​‌‌​‍‌‌​‌​‌‌‍‌‌​​​​‌‍‌​‌​‌‌‌‍​‌‌‌​​​‍‌‌​​‌‌‌‍‌​​‌‌​‌‍‌‌​‌​‌​‍‌​​​​‌​‍‌​‌​‌​‌‍‌​‌​​​‌‍‌‌​‌‌​​‍‌​​​​‌​‍‌​​‌‌‌​‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​‌​‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​‌​​‍‌​​​‌​‌‍‌‌‌‌​​​‍‌​​‌‌‌​‍‌‌‌​‌‌​‍​‌​‌‌‌‌‍​‌‌​‌‌​‍‌​​‌​​‌‍‌​​​‌‌‌‍‌‌‌‌​‌​‍​‌‌‌​​‌‍​‌‌​‌‌​‍‌‌​​‌‌‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​​​​‌‍‌​​‌‌​​‍‌​‌‌​​‌‍‌​​​​​‌‍‌​‌​​​‌‍‌​​​​​‌‍‌​‌​‌​‌‍‌​
@endolith
endolith / Perfect_FFT.py
Last active June 16, 2023 08:25
Perfect FFT
from numpy import linspace, cos, pi, absolute
from numpy.fft import fft, fftfreq, fftshift
import matplotlib.pyplot as plt
# Sampling rate
fs = 64 # Hz
# Time is from 0 to 1 seconds, but leave off the endpoint, so
# that 1.0 seconds is the first sample of the *next* chunk
length = 1 # second