From c0f7c0c571123f0bab4a8cd092eb7a8f1da32c80 Mon Sep 17 00:00:00 2001 From: Sebastian Baunsgaard Date: Tue, 24 Sep 2024 15:50:46 +0200 Subject: [PATCH] fix errors --- .../dictionary/IdentityDictionary.java | 24 ------------------- .../runtime/compress/lib/CLALibCompAgg.java | 2 +- 2 files changed, 1 insertion(+), 25 deletions(-) diff --git a/src/main/java/org/apache/sysds/runtime/compress/colgroup/dictionary/IdentityDictionary.java b/src/main/java/org/apache/sysds/runtime/compress/colgroup/dictionary/IdentityDictionary.java index 4cf86f357e0..7a76f308523 100644 --- a/src/main/java/org/apache/sysds/runtime/compress/colgroup/dictionary/IdentityDictionary.java +++ b/src/main/java/org/apache/sysds/runtime/compress/colgroup/dictionary/IdentityDictionary.java @@ -350,10 +350,6 @@ public double[] productAllRowsToDoubleWithReference(double[] reference) { public void colSum(double[] c, int[] counts, IColIndex colIndexes) { for(int i = 0; i < colIndexes.size(); i++) c[colIndexes.get(i)] += counts[i]; -<<<<<<< HEAD -======= - ->>>>>>> cb91b16977 ([DO NOT MERGE] JAVA 17 BWARE COMMIT) } @Override @@ -434,18 +430,8 @@ public long getNumberNonZerosWithReference(int[] counts, double[] reference, int } @Override -<<<<<<< HEAD public final void addToEntry(final double[] v, final int fr, final int to, final int nCol) { addToEntry(v, fr, to, nCol, 1); -======= - - public void addToEntry(final double[] v, final int fr, final int to, final int nCol) { - // getMBDict().addToEntry(v, fr, to, nCol); - if(!withEmpty) - v[to * nCol + fr] += 1; - else if(fr < nRowCol) - v[to * nCol + fr] += 1; ->>>>>>> cb91b16977 ([DO NOT MERGE] JAVA 17 BWARE COMMIT) } @Override @@ -675,13 +661,8 @@ public void MMDictDense(double[] left, IColIndex rowsLeft, IColIndex colsRight, final int colsOut = result.getNumColumns(); final int commonDim = Math.min(left.length / leftSide, nRowCol); final double[] resV = result.getDenseBlockValues(); -<<<<<<< HEAD for(int i = 0; i < leftSide; i++) { // rows in left side final int offOut = rowsLeft.get(i) * colsOut; -======= - for(int i = 0; i < leftSide; i++) {// rows in left side - final int offOut = rowsLeft.get(i) * resCols; ->>>>>>> cb91b16977 ([DO NOT MERGE] JAVA 17 BWARE COMMIT) final int leftOff = i; for(int j = 0; j < commonDim; j++) { // cols in left side skipping empty from identity resV[offOut + colsRight.get(j)] += left[leftOff + j * leftSide]; @@ -752,15 +733,10 @@ public void TSMMToUpperTriangleSparseScaling(SparseBlock left, IColIndex rowsLef @Override public boolean equals(IDictionary o) { -<<<<<<< HEAD if(o instanceof IdentityDictionary && // ((IdentityDictionary) o).nRowCol == nRowCol && // ((IdentityDictionary) o).withEmpty == withEmpty) return true; -======= - if(o instanceof IdentityDictionary) - return ((IdentityDictionary) o).nRowCol == nRowCol && ((IdentityDictionary) o).withEmpty == withEmpty; ->>>>>>> cb91b16977 ([DO NOT MERGE] JAVA 17 BWARE COMMIT) return getMBDict().equals(o); } diff --git a/src/main/java/org/apache/sysds/runtime/compress/lib/CLALibCompAgg.java b/src/main/java/org/apache/sysds/runtime/compress/lib/CLALibCompAgg.java index ff7d5ee07bb..5b9d7e7f099 100644 --- a/src/main/java/org/apache/sysds/runtime/compress/lib/CLALibCompAgg.java +++ b/src/main/java/org/apache/sysds/runtime/compress/lib/CLALibCompAgg.java @@ -314,7 +314,7 @@ private static boolean isValidForParallelProcessing(CompressedMatrixBlock m1, Ag } private static void aggregateInParallel(CompressedMatrixBlock m1, MatrixBlock ret, AggregateUnaryOperator op, - int k) { + int k) throws Exception { final ExecutorService pool = CommonThreadPool.get(k); try { final ArrayList tasks = new ArrayList<>();