Skip to content

Commit

Permalink
Merge pull request #36 from haesemeyer/haesemeyer-patch-1
Browse files Browse the repository at this point in the history
Update snmf.py to fix issue #35
  • Loading branch information
marinkaz committed Oct 3, 2016
2 parents 4c91274 + 60d864e commit 06ba26b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions nimfa/methods/factorization/snmf.py
Expand Up @@ -170,12 +170,14 @@ def factorize(self):
Return fitted factorization model.
"""
# in version SNMF/L, V is transposed while W and H are swapped and
# transposed.
if self.version == 'l':
self.V = self.V.T


for run in range(self.n_run):
# in version SNMF/L, V is transposed while W and H are swapped and
# transposed.
if self.version == 'l':
self.V = self.V.T

self.W, self.H = self.seed.initialize(
self.V, self.rank, self.options)
if sp.isspmatrix(self.W):
Expand Down

0 comments on commit 06ba26b

Please sign in to comment.