org.apache.sysds.runtime.util

## Class Py4jConverterUtils

- java.lang.Object
- - org.apache.sysds.runtime.util.Py4jConverterUtils

-     public class Py4jConverterUtils
      extends Object

  Utils for converting python data to java.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Py4jConverterUtils()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static MatrixBlock` | `allocateDenseOrSparse(int rlen, int clen, boolean isSparse)`
    `static MatrixBlock` | `allocateDenseOrSparse(long rlen, long clen, boolean isSparse)`
    `static byte[]` | `convertMBtoPy4JDenseArr(MatrixBlock mb)`
    `static MatrixBlock` | `convertPy4JArrayToMB(byte[] data, int rlen, int clen)`
    `static MatrixBlock` | `convertPy4JArrayToMB(byte[] data, int rlen, int clen, boolean isSparse, Types.ValueType valueType)`
    `static MatrixBlock` | `convertPy4JArrayToMB(byte[] data, int rlen, int clen, Types.ValueType valueType)`
    `static MatrixBlock` | `convertSciPyCOOToMB(byte[] data, byte[] row, byte[] col, int rlen, int clen, int nnz)`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Py4jConverterUtils

          public Py4jConverterUtils()

  - ### Method Detail

    - #### convertPy4JArrayToMB

          public static MatrixBlock convertPy4JArrayToMB(byte[] data,
                                                         int rlen,
                                                         int clen)

    - #### convertPy4JArrayToMB

          public static MatrixBlock convertPy4JArrayToMB(byte[] data,
                                                         int rlen,
                                                         int clen,
                                                         Types.ValueType valueType)

    - #### convertSciPyCOOToMB

          public static MatrixBlock convertSciPyCOOToMB(byte[] data,
                                                        byte[] row,
                                                        byte[] col,
                                                        int rlen,
                                                        int clen,
                                                        int nnz)

    - #### allocateDenseOrSparse

          public static MatrixBlock allocateDenseOrSparse(int rlen,
                                                          int clen,
                                                          boolean isSparse)

    - #### allocateDenseOrSparse

          public static MatrixBlock allocateDenseOrSparse(long rlen,
                                                          long clen,
                                                          boolean isSparse)

    - #### convertPy4JArrayToMB

          public static MatrixBlock convertPy4JArrayToMB(byte[] data,
                                                         int rlen,
                                                         int clen,
                                                         boolean isSparse,
                                                         Types.ValueType valueType)

    - #### convertMBtoPy4JDenseArr

          public static byte[] convertMBtoPy4JDenseArr(MatrixBlock mb)

Copyright © 2020 The Apache Software Foundation. All rights reserved.