Chroma.py
def sqrtCompress(X):
    """
    Square root compress chroma bin values
    :param X: An (NBins x NWindows) array of chroma
    :returns Y: An (NBins x NWindows) sqrt normalized
        chroma matrix
    """
    Norms = np.sqrt(np.sum(X**2, 0))
    Norms[Norms == 0] = 1
    Y = (X/Norms[None, :])**0.5
    NewNorms = np.sqrt(np.sum(Y**2, 0))
    NewNorms[NewNorms == 0] = 1
    Y = Y*(Norms[None, :]/NewNorms[None, :])
    return Y

    Square root compress chroma bin values
    :param X: An (NBins x NWindows) array of chroma
    :returns Y: An (NBins x NWindows) sqrt normalized
        chroma matrix
    
Square root compress chroma bin values
Square root compress chroma bin values
def sqrtCompress(X):
    Norms = np.sqrt(np.sum(X**2, 0))
    Norms[Norms == 0] = 1
    Y = (X/Norms[None, :])**0.5
    NewNorms = np.sqrt(np.sum(Y**2, 0))
    NewNorms[NewNorms == 0] = 1
    Y = Y*(Norms[None, :]/NewNorms[None, :])
    return Y
def sqrtCompress ( X ) : Norms = np . sqrt ( np . sum ( X ** 2 , 0 ) ) Norms [ Norms == 0 ] = 1 Y = ( X / Norms [ None , : ] ) ** 0.5 NewNorms = np . sqrt ( np . sum ( Y ** 2 , 0 ) ) NewNorms [ NewNorms == 0 ] = 1 Y = Y * ( Norms [ None , : ] / NewNorms [ None , : ] ) return Y
Square root compress chroma bin values
Square root compress chroma bin values
"""
    Square root compress chroma bin values
    :param X: An (NBins x NWindows) array of chroma
    :returns Y: An (NBins x NWindows) sqrt normalized
        chroma matrix
    """
An (NBins x NWindows) sqrt normalized
chroma matrix
An ( NBins x NWindows ) sqrt normalized chroma matrix
Y
X
An (NBins x NWindows) array of chroma
An ( NBins x NWindows ) array of chroma