<commit_before>import numpy as np
from scipy.fftpack import fft, fftshift


def CalcFourier(signal, fs, fc):

    step = 1 / fs
    pole = fs

    transform = 20 * np.log10(np.absolute(fftshift(fft(signal)) / len(signal)))<commit_msg>Added doc string<commit_after>"""
    **Author :** *<NAME>*

    This module computes the length normalized fourier transform of the signal.

"""
import numpy as np
from scipy.fftpack import fft, fftshift


def CalcFourier(signal, fs, fc):
    """
        This function calculates the fourier transform of a signal. The fourier transform's
        zero frequency is shifted to the centre of the spectrum. Further the fourier transform
        is length normalized.

        Parameters
        -------------------------
            signal : ndarray
                Numpy complex array of shifted signal.
            fs : float
                Sampling frequency of the signal.
            fc : float
                Centre frequency of the signal.

        Returns
        -----------------------
            frequency : ndarray
                Numpy array of values of frequencies present in the signal.
            transform : ndarray
                Numpy array of computed fourier transform.

    """
    step = 1 / fs
    pole = fs

    transform = 20 * np.log10(np.absolute(fftshift(fft(signal)) / len(signal)))
{'fraction_non_alphanumeric': 0.1037037037037037, 'fraction_numerical': 0.007407407407407408, 'mean_word_length': 1.874468085106383, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2835450', 'n_tokens_mistral': 370, 'n_tokens_neox': 342, 'n_words': 132}