Permalink
Browse files

some cleanup of the codes.

  • Loading branch information...
1 parent eef2bd5 commit 540a6122df714a3cffe3f8abf5ca3ff08abad326 @lindahua lindahua committed Dec 31, 2013
View
@@ -90,7 +90,7 @@ function affprop_update_message!{T<:FloatingPoint}(psi::Matrix{T}, phi::Matrix{T
I = indmax(SM)
Y = SM[I]
SM[I] = -Inf
- Y2 = max(SM)
+ Y2 = maximum(SM)
val = S[i,:] - Y;
val[I] = S[i,I] - Y2;
phi[i,:] = opts.damp*phi[i,:] + (1-opts.damp)*val
File renamed without changes.
View
@@ -1,18 +0,0 @@
-# a simple benchmark
-
-using Clustering
-
-m = 100
-n = 10000
-k = 50
-
-x = rand(m, n)
-
-# warming
-kmeans(x[:,1:1000], 2; display=:none, max_iter=200)
-
-println("kmeans on $n samples (of dimension $m) with K = $k ...")
-t_new = @elapsed r_new = kmeans(x, k; display=:none, max_iter=200)
-println("\telapsed = $t_new, per_iteration = $(t_new / r_new.iterations)")
-println()
-
File renamed without changes.

0 comments on commit 540a612

Please sign in to comment.