21a6d7c02d8919ac29b5aa0af8992ba13f0a3ddb,prody/chromatin/cluster.py,,calcGNMDomains,#Any#Any#,190

Before Change



    labels_ = method(V, **kwargs)

    if np.all(mask):
        labels = labels_
    else:
        labels = np.empty(len(mask))
        labels.fill(np.nan)
        labels[mask] = labels_

        currlbl = labels_[np.argmax(~np.isnan(labels_))]

        for i, l in enumerate(labels):
            if np.isnan(l):
                labels[i] = currlbl
            elif currlbl != l:
                currlbl = l

    return labels

After Change



    if hasattr(modes, "_model"):
        model = modes._model
        if isinstance(model, MaskedGNM):
            labels = model._extend(labels_, np.nan)
            currlbl = labels_[0]

            for i, l in enumerate(labels):
                if np.isnan(l):
                    labels[i] = currlbl
                elif currlbl != l:
                    currlbl = l

    return labels
    
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: prody/ProDy
Commit Name: 21a6d7c02d8919ac29b5aa0af8992ba13f0a3ddb
Time: 2019-07-08
Author: shz66@pitt.edu
File Name: prody/chromatin/cluster.py
Class Name:
Method Name: calcGNMDomains


Project Name: sentinel-hub/eo-learn
Commit Name: 502d7b4705040a21be3b4da40f33437c1fb2c0e7
Time: 2020-01-03
Author: matej.aleksandrov@sinergise.com
File Name: core/eolearn/core/utilities.py
Class Name:
Method Name: deep_eq


Project Name: analysiscenter/batchflow
Commit Name: 327235adabdcdff566ff74413795091353dcfc1f
Time: 2019-10-16
Author: 53620809+cdtn@users.noreply.github.com
File Name: batchflow/models/metrics/utils.py
Class Name:
Method Name: infmean


Project Name: Ambrosys/glyph
Commit Name: b25ea4418ee72f673a67615a32f866bd1fc6e1d7
Time: 2017-02-20
Author: mquade@uni-potsdam.de
File Name: glyph/assessment.py
Class Name:
Method Name: replace_nan