d

CepstraResearch

Let’s Work Together

n

Frequency Band Segregation

Frequency Band Segregation

By Data Science Team, Cepstra Research LLP

In music personalization, people tend to prefer a particular set of instruments over others. For instance, listeners may prefer a song with acoustic instruments like guitar and cello over electronically generated bass. For this purpose, we decided to dive into a branch of research that can distinguish between the songs containing a different set of instrument mixture and add this as a feature to the music recommendation system.

After a brief research period, we recognized that a certain set of instruments, if played together, produces a frequency that is similar to the same set of instruments played in a different song.

In other words, there seems to be a behavioral pattern that is followed when the same instruments are played together in different songs. This finding leads us to craft a code that can segregate these frequencies and help us improve the music recommendation system.

The song is loaded and chunked into lumps of 10 milliseconds file. The individual files are processed with Fast Fourier Transform (FFT) to convert the chunk from a time domain to a frequency domain. Since there are multiple frequencies present in the frequency band we needed the find the maximum frequency and load it into a list to further process it down.

To do this,  We study  FFT(Fast Fourier Transform) of the chunk of frequencies.

To calculate the frequency in hertz

X(k)=\sum_{n=0}^{N-1} x(n)^{*} e^{-i^{*} 2^{*} \pi  n^{*} k / N}

When the frequency at every chunk is obtained, the task remains to segregate them to their respective frequency bands. We have given a summary of the theory on which we have based this research on.

The deepness of music is actually the low range frequency which produces the frequency range from 20 Hz to 200 Hz. That means any song having a base feature like a free kick in a soccer match will have a low-frequency range. The low frequencies have a greater wavelength, as a result, it sounds thick and deep. This frequency range is produced by 

Lower mid-range carries the musical bass in your song for example notes from a bass guitar, a low note in saxophone or a thick flute. You can think of it as the flooring of your music as it provides the heaviness to your music. This frequency range, as well as the higher mid-range, is produced by the surround of the diaphragm in a speaker.

The treble part lies between 1000 Hz to 5000 Hz of the song and this where most of the magic happens. From high-pitched voice to the guitar solos this is the most important part of the frequency regarding the melody and therefore it is also known as the full range of presence. This frequency is also the result of the surrounding part in a speaker.

This section of the frequency range above 5000Hz is the high pitched section. The bright music everyone talks about, that’s the outcome of the frequency in this range. The whistle and the sharp pieces of the triangle you hear in a piece of music belongs to this range. This frequency range is produced by a driver called tweeter in a speaker.

At Cepstra we study music keeping these values in the base of the algorithm, and generate various human-understandable characteristic of the music. 

Add Comment