Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New stop condition: use component relative change
Previously, convergence was achieved when `|W[i, j]-preW[i, j]|<=tol for all i, j`. Running NMF on `10*X` (where `X` is the data matrix ) would increase the number of iterations compared to NMF on `X`. Now, `||W[:, j]-preW[:, j]||/||W[:, j]+preW[:, j]||<=tol for all j` is the new convergence criterion, which is relative difference rather absolute difference and thus, it is scale invariant.
- Loading branch information