Skip to content

Commit

Permalink
fix #16: initialize H in nnmf (#25)
Browse files Browse the repository at this point in the history
Projected ALS does not need H initialized, all others do
  • Loading branch information
korenmiklos committed Oct 23, 2020
1 parent c75136e commit 9c2ab61
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/interf.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ function nnmf(X::AbstractMatrix{T}, k::Integer;
k <= min(p, n) || throw(ArgumentError("The value of k should not exceed min(size(X))."))

# determine whether H needs to be initialized
initH = alg == :projals
initH = alg != :projals

# perform initialization
if init == :random
Expand Down

0 comments on commit 9c2ab61

Please sign in to comment.