Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.encog.ml.data.buffer.codec
Interface DataSetCODEC

All Known Implementing Classes:
  ArrayDataCODEC, CSVDataCODEC, ExcelCODEC, NeuralDataSetCODEC, SQLCODEC

    public interface DataSetCODEC

A CODEC is used to encode and decode data. The DataSetCODEC is designed to move data to/from the Encog binary training file format, used by BufferedNeuralDataSet. CODECs are provided for such items as CSV files, arrays and many other sources.

Method Summary
`void` | `close()` Close any open files.
`int` | `getIdealSize()`
`int` | `getInputSize()`
`void` | `prepareRead()` Prepare to read from an external data source.
`void` | `prepareWrite(int recordCount, int inputSize, int idealSize)` Prepare to write to an external data destination.
`boolean` | `read(double[] input, double[] ideal, double[] significance)` Read one record of data from an external source.
`void` | `write(double[] input, double[] ideal, double significance)` Write one record of data to an external destination.

Method Detail

### read

    boolean read(double[] input,
                 double[] ideal,
                 double[] significance)

  Read one record of data from an external source.

  Parameters:
    `input` - The input data array.
    `ideal` - The ideal data array.
    `signidicance` - The significance. The first element will be modified to hold the significance.
  Returns:
    True, if there is more data to be read.

### write

    void write(double[] input,
               double[] ideal,
               double significance)

  Write one record of data to an external destination.

  Parameters:
    `input` - The input data array.
    `ideal` - The ideal data array.

### prepareWrite

    void prepareWrite(int recordCount,
                      int inputSize,
                      int idealSize)

  Prepare to write to an external data destination.

  Parameters:
    `recordCount` - The total record count, that will be written.
    `inputSize` - The input size.
    `idealSize` - The ideal size.

### prepareRead

    void prepareRead()

  Prepare to read from an external data source.

### getInputSize

    int getInputSize()

  Returns:
    The size of the input data.

### getIdealSize

    int getIdealSize()

  Returns:
    The size of the ideal data.

### close

    void close()

  Close any open files.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2011. All Rights Reserved.