192193194195196197198199200201202203
@Override public ByteMatrix createDiagonalMatrix(byte[] diagonal) { final int size = diagonal.length; ByteMatrix matrix = new CRSByteMatrix(size, size); for (int i = 0; i < size; i++) { matrix.set(i, i, diagonal[i]); } return matrix; }
220221222223224225226
colInds[i][j] = Serialization.readMatrixColumnIndex(buffer); colVals[i][j] = Serialization.readMatrixValue(buffer); } } return new CRSByteMatrix(rows, cols, colVals, colInds, rowCards); }
243244245246247248249
colInds[i][j] = Serialization.readMatrixColumnIndex(ch); colVals[i][j] = Serialization.readMatrixValue(ch); } } return new CRSByteMatrix(rows, cols, colVals, colInds, rowCards); }