Monday, January 22, 2024

Updated Fourier Transform

I've updated my FFT code to present spectral data (in either accelerometer data, or sound data, or CA data, or whatever) in the correct way.  There was nothing necessarily *wrong* with how I've been doing it, but now I can take full advantage of the temporal aspects of the data.  With the old code, I was limited to a temporal resolution proportional to the size of the FFT window.  Now I have full control of the time resolution up to the Nyquist frequency.  With an improved time resolution, the resulting spectrograms can (and usually will) look much better than before.

The downside to this is that the output data has much larger dimensions.  For example, audio data that comes in at 44.1k Hz (normal audio recording), means that one second of data using a 1024 window FFT, results in a spectrogram that's 512 x 44,100 pixels in size!  If I have a recording that's five minutes long, that's a spectrogram that's 512 x 13,230,000 pixels in size!  I can easily deal with this by not using every data point, but rather every X data points, where X can be interval I want.  This effectively widens the time interval between individual spectra, but in actuality there are very few instances where I'm going to need a sampling rate anything higher than maybe 5k Hz.  So I can use an 'X' value of 100, and still be measuring data every 0.0022 seconds.

Anyhow, this is more of an internal improvement to the code and not very visible to anyone but me.

Here's 5 seconds of the complex call of a Curve-Billed Thrasher (for which I'm fortunate to have such a creative songbird literally right outside my window year-round).  Time goes left to right (0 to 5 seconds), and frequency goes bottom to top (0 to 22.05k Hz):



Listening to the sounds and looking at the spectrograms has got me very interested in trying to make sense of these sounds.  It's automatic for me: start running the scientific method on this stuff and see where it leads me.  LOL like to many other things, probably nowhere!

Monday, January 1, 2024

Sandhill Cranes Generated by DALL-E3

Pretty impressive...

Prompt: generate a 1794 by 1024 realistic image of a sandhill crane in flight over a playa in southeastern arizona usa





and then a further prompt: generate two more images,  but with about five sandhill cranes



Prompt: generate 1794 by 1024 images of a sandhill crane in flight over a playa in southeastern arizona usa. draw it in a way a 5 year old child would with crayon



Prompt: please make them more simplistic and drawn by a child under the age of five



prompt: please generate two more images in the same style, but draw a small flock of sandhill cranes



 I really dig the shadows on that last one.  The creation of a 5-year-old child?  Sure!