Main Content

read

Read data from datastore

Since R2024a

    Description

    data = read(DS) returns data from a DLCHOMP datastore. Subsequent calls to the read function continue reading from the endpoint of the previous call.

    [data,info] = read(DS) also returns information about the extracted data in info, including metadata.

    Input Arguments

    collapse all

    Input datastore, specified as a dlCHOMPDatastore object.

    Output Arguments

    collapse all

    Output data, returned as a three-element cell array with these elements:

    1. 2*M-element numeric vector of the first and last waypoints of the Trajectory field of the input JSON file, concatenated row-wise. M is the number of joints in the robot rigid body tree.

    2. E-element numeric vector of the obstacle encoding from the Encoding field of the input JSON file. E is the size of the basis point set.

    3. (W–2)*M numeric vector of the intermediate waypoints of the Trajectory field of the input JSON file. W is the number of waypoints. M is the number of joints in the robot rigid body tree.

    Use the first and second elements as inputs, and the third element as the corresponding output, to train the neural network stored in a dlCHOMP object by using the trainDLCHOMP function.

    Information about read data, returned as a structure array. The structure array contains these fields.

    Field NameDescription
    Size

    Size of the data output

    FileName

    Fully resolved path to the JSON file being read, containing the path string, name of the file, and file extension.

    Offset

    Starting position of the read operation, in bytes.

    Version History

    Introduced in R2024a