42dcbde0e602cba7adb911a2072df3887afd61f4,hicexplorer/utilities.py,,exp_obs_matrix_lieberman,#Any#Any#Any#,215

Before Change


    distance = np.ceil(np.absolute(row - col) / 2).astype(np.int32)
    for i in range(len(pSubmatrix.data)):
        try:
            if expected_interactions_in_distance_[distance[i]] == 0:
                pSubmatrix.data[i] = 0.0
            else:
                pSubmatrix.data[i] = pSubmatrix.data[i] / expected_interactions_in_distance_[distance[i]]
        except Exception:
            log.debug("pSubmatrix.data[i]: {}".format(pSubmatrix.data[i]))
            log.debug("distance[i]: {}".format(distance[i]))
            log.debug("expected_interactions_in_distance_[distance[i]]: {} ".format(expected_interactions_in_distance_[distance[i]]))

After Change


        expected = expected_interactions_in_distance_[distance]
        // log.info("len(expected); {}".format(len(expected)))
        // log.info("len(data): {}".format(len(pSubmatrix.data)))
        pSubmatrix.data = pSubmatrix.data.astype(np.float32)
        pSubmatrix.data /= expected
        // data2 = deepcopy(data)
        pSubmatrix.data = convertInfsToZeros_ArrayFloat(pSubmatrix.data).astype(data_type)


    // for i in range(len(pSubmatrix.data)):
    //     try:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: deeptools/HiCExplorer
Commit Name: 42dcbde0e602cba7adb911a2072df3887afd61f4
Time: 2018-03-03
Author: wolffj@informatik.uni-freiburg.de
File Name: hicexplorer/utilities.py
Class Name:
Method Name: exp_obs_matrix_lieberman


Project Name: scikit-learn-contrib/DESlib
Commit Name: 8115a167b0f280a62aa0d5560709ab9790d96e15
Time: 2020-05-19
Author: rafaelmenelau@gmail.com
File Name: deslib/util/aggregation.py
Class Name:
Method Name: weighted_majority_voting_rule


Project Name: openai/gym
Commit Name: cee92691ad858952b4ed46c08cad6cc682868d22
Time: 2019-03-24
Author: zuoxingdong@users.noreply.github.com
File Name: gym/spaces/box.py
Class Name: Box
Method Name: __init__