zhengruifeng commented on a change in pull request #27758:
URL: https://github.com/apache/spark/pull/27758#discussion_r411908260



##########
File path: mllib-local/src/main/scala/org/apache/spark/ml/impl/Utils.scala
##########
@@ -27,4 +27,55 @@ private[ml] object Utils {
     }
     eps
   }
+
+  /**
+   * Convert an n * (n + 1) / 2 dimension array representing the upper 
triangular part of a matrix
+   * into an n * n array representing the full symmetric matrix (column major).
+   *
+   * @param n The order of the n by n matrix.
+   * @param triangularValues The upper triangular part of the matrix packed in 
an array
+   *                         (column major).
+   * @return A dense matrix which represents the symmetric matrix in column 
major.
+   */
+  def unpackUpperTriangular(

Review comment:
       I can't find a packing or indexing method in scala or commons-math




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to