32d73ccb0d80db3727775fb9928f5f151ddaaab5,nt/speech_enhancement/mask_estimation.py,,simple_ideal_soft_mask,#,44

Before Change


        X = input[0]

    // Permute if nessesary
    if feature_dim != -2 or source_dim != -1:
        r = list(range(np.ndim(X)))
        r[feature_dim], r[-2] = r[-2], r[feature_dim]
        r[source_dim], r[-1] = r[-1], r[source_dim]
        X = np.transpose(X, axes=r)

    power = np.einsum("...dk,...dk->...k", X.conjugate(), X)
    mask = (power / np.sum(power, axis=power.ndim-1, keepdims=True)).real

    return mask

After Change


    if not tuple_output:
        return np.squeeze(mask, axis=feature_dim)
    else:
        sizes = np.cumsum([o.shape[source_dim] for o in input])
        output = np.split(mask, sizes[:-1], axis=source_dim)

        for i in range(len(output)):
            if output[i].shape[source_dim] is 1:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 5

Instances


Project Name: fgnt/pb_bss
Commit Name: 32d73ccb0d80db3727775fb9928f5f151ddaaab5
Time: 2015-10-06
Author: cbj@mail.uni-paderborn.de
File Name: nt/speech_enhancement/mask_estimation.py
Class Name:
Method Name: simple_ideal_soft_mask


Project Name: arraiy/torchgeometry
Commit Name: a4fe3a3fea83a260ad22f45e928d0eec6862fadc
Time: 2020-11-25
Author: sj8716643@126.com
File Name: kornia/color/hsv.py
Class Name:
Method Name: rgb_to_hsv


Project Name: stellargraph/stellargraph
Commit Name: 19efebad71288796c490f7dfcc4092afee646611
Time: 2020-05-27
Author: kieranricardo@hotmail.com
File Name: stellargraph/data/explorer.py
Class Name:
Method Name: naive_weighted_choices


Project Name: DagnyT/hardnet
Commit Name: 04cd555be76efc7baced753c751c4257d41eb75d
Time: 2017-07-27
Author: ducha.aiki@gmail.com
File Name: EvalMetrics.py
Class Name:
Method Name: ErrorRateAt95Recall