4346ff930104b0d9b6735090a1ce4c485d40b981,pymanopt/manifolds/grassmann.py,Grassmann,retr,#Grassmann#,105

Before Change


            u, s, vt = svd(X + G, full_matrices=False)
            XNew = u.dot(vt)
        else:
            XNew = np.zeros(np.shape(X))
            for i in xrange(self._k):
                // q, r = np.linalg.qr(Y[i])
                // XNew[i] = np.dot(q, np.diag(np.sign(np.sign(np.diag(r))+.5)))
                u, s, vt = svd(X[i] + G[i], full_matrices=False)
                XNew[i] = u.dot(vt)
        return XNew

    def norm(self, X, G):
        // Norm on the tangent space is simply the Euclidean norm.

After Change



        // Compute the polar factorization of Y = X+G
        u, s, vt = svd(X + G, full_matrices=False)
        return multiprod(u, vt)

    def norm(self, X, G):
        // Norm on the tangent space is simply the Euclidean norm.
        return np.linalg.norm(G)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: pymanopt/pymanopt
Commit Name: 4346ff930104b0d9b6735090a1ce4c485d40b981
Time: 2016-02-25
Author: jamiehntownsend@gmail.com
File Name: pymanopt/manifolds/grassmann.py
Class Name: Grassmann
Method Name: retr


Project Name: broadinstitute/keras-rcnn
Commit Name: 625fbd05fef5c015c9b0e9cedbf12f639a6b5a76
Time: 2020-05-19
Author: allen.goodman@icloud.com
File Name: keras_rcnn/backend/tensorflow_backend.py
Class Name:
Method Name: scatter_add_tensor


Project Name: pymanopt/pymanopt
Commit Name: a4566752a9207c7769e00c97e08f905d601f27e9
Time: 2016-02-15
Author: jamiehntownsend@gmail.com
File Name: pymanopt/tools/multi.py
Class Name:
Method Name: multiprod