def process(self, n, c): sz = len(self.keys) if self.gp is not None: self.gp += (form_csr_matrix(self.data,sz,n).T.dot(np.random.randn(sz,c))).T else: self.gp = (form_csr_matrix(self.data,sz,n).T.dot(np.random.randn(sz,c))).T return iter([])
def process(self, n, c): sz = len(self.keys) if self.gp is not None: self.gp += (form_csr_matrix(self.data, sz, n).T.dot(np.random.randn(sz, c))).T else: self.gp = (form_csr_matrix(self.data, sz, n).T.dot(np.random.randn(sz, c))).T return iter([])
def process(self, mat, n): data = form_csr_matrix(self.data,len(self.keys),n) if self.atamat is not None: self.atamat += data.T.dot( data.dot(mat) ) else: self.atamat = data.T.dot( data.dot(mat) ) return iter([])
def process(self, mat, n): data = form_csr_matrix(self.data, len(self.keys), n) if self.atamat is not None: self.atamat += data.T.dot(data.dot(mat)) else: self.atamat = data.T.dot(data.dot(mat)) return iter([])