Class JsonFormat

    • Constructor Detail

      • JsonFormat

        public JsonFormat()
    • Method Detail

      • encode

        public static byte[] encode​(Tensor tensor)
        Serializes the given tensor value into JSON format
      • encodeWithType

        public static byte[] encodeWithType​(Tensor tensor)
        Serializes the given tensor type and value into JSON format
      • encodeShortForm

        public static byte[] encodeShortForm​(Tensor tensor)
        Serializes the given tensor type and value into a short-form JSON format
      • decode

        public static Tensor decode​(TensorType type,
                                    byte[] jsonTensorValue)
        Deserializes the given tensor from JSON format