Package org.encog.ml.data

Examples of org.encog.ml.data.MLDataError


   * @param data1
   *            The data to be added.
   */
  public void add(final MLData data1) {
    if (!this.loading) {
      throw new MLDataError(BufferedMLDataSet.ERROR_ADD);
    }

    egb.write(data1.getData());
    egb.write(1.0);
  }
View Full Code Here


   *            The ideal data.
   */
  public void add(final MLData inputData, final MLData idealData) {

    if (!this.loading) {
      throw new MLDataError(BufferedMLDataSet.ERROR_ADD);
    }

    this.egb.write(inputData.getData());
    this.egb.write(idealData.getData());
    this.egb.write((double) 1.0);
View Full Code Here

   * @param pair
   *            The pair to add.
   */
  public void add(final MLDataPair pair) {
    if (!this.loading) {
      throw new MLDataError(BufferedMLDataSet.ERROR_ADD);
    }

    this.egb.write(pair.getInputArray());
    this.egb.write(pair.getIdealArray());
    this.egb.write(pair.getSignificance());
View Full Code Here

    try {
      // prepare the statement
      this.statement = this.connection.prepareStatement(theSQL);
    } catch (final SQLException e) {
      throw new MLDataError(e);
    }
  }
View Full Code Here

      // prepare the statement
      this.statement = this.connection.prepareStatement(theSQL);

    } catch (final ClassNotFoundException e) {
      throw new MLDataError(e);
    } catch (final SQLException e) {
      throw new MLDataError(e);
    }
  }
View Full Code Here

      if (this.closeConnection) {
        this.connection.close();
      }
      this.results.close();
    } catch (final SQLException e) {
      throw new MLDataError(e);
    }
  }
View Full Code Here

        this.statement.setFetchSize(this.fetchSize);
      }
      // execute the statement
      this.results = this.statement.executeQuery();
    } catch (final SQLException e) {
      throw new MLDataError(e);
    }
  }
View Full Code Here

   */
  @Override
  public void prepareWrite(final int recordCount,
      final int theInputSize,
      final int theIdealSize) {
    throw new MLDataError("Write not supported.");
  }
View Full Code Here

      }

      significance[0] = 1;
      return true;
    } catch (final SQLException e) {
      throw new MLDataError(e);
    }
  }
View Full Code Here

  /**
   * {@inheritDoc}
   */
  @Override
  public void write(final double[] input, final double[] ideal, double significance) {
    throw new MLDataError("Write not supported.");
  }
View Full Code Here

TOP

Related Classes of org.encog.ml.data.MLDataError

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.