Examples of optimize()


Examples of org.apache.commons.math.optimization.linear.SimplexSolver.optimize()

            GoalType.MINIMIZE : GoalType.MAXIMIZE;
    IValueFactory vf = values;
    boolean nonNegativeJ =  nonNegative.getValue();
    try {
      RealPointValuePair res =
          solver.optimize(fJ, constraintsJ, goal,nonNegativeJ);
      return vf.constructor(Maybe.Maybe_just,
          vf.constructor(
              LLSolution_llSolution, convertToRealList(res.getPoint(), vf),
              vf.real(res.getValue()) )
          );
View Full Code Here

Examples of org.apache.commons.math.optimization.univariate.BrentOptimizer.optimize()

                          Function fn, double lower, double upper, double tol) {

    BrentOptimizer optimizer = new BrentOptimizer();
    optimizer.setAbsoluteAccuracy(tol);
    try {
      return optimizer.optimize(new UnivariateRealClosure(context, rho, fn), GoalType.MINIMIZE, lower, upper);
    } catch (MaxIterationsExceededException e) {
      throw new EvalException("maximum iterations reached", e);
    } catch (FunctionEvaluationException e) {
      throw new EvalException(e);
    }
View Full Code Here

Examples of org.apache.commons.math3.optim.nonlinear.scalar.noderiv.SimplexOptimizer.optimize()

                wrapped.boundedToUnbounded(new double[] { 1.5, 2.95 }),
                wrapped.boundedToUnbounded(new double[] { 1.7, 2.90 })
            });

        final PointValuePair optimum
            = optimizer.optimize(new MaxEval(300),
                                 new ObjectiveFunction(wrapped),
                                 simplex,
                                 GoalType.MINIMIZE,
                                 new InitialGuess(wrapped.boundedToUnbounded(new double[] { 1.5, 2.25 })));
        final double[] bounded = wrapped.unboundedToBounded(optimum.getPoint());
View Full Code Here

Examples of org.apache.commons.math3.optimization.MultivariateOptimizer.optimize()

        final int maxEval = 1000;
        // Very small absolute tolerance to rely solely on the relative
        // tolerance as a stopping criterion
        final MultivariateOptimizer optim = new PowellOptimizer(relTol, 1e-100);

        final PointValuePair funcResult = optim.optimize(maxEval, func, GoalType.MINIMIZE, init);
        final double funcValue = func.value(funcResult.getPoint());
        final int funcEvaluations = optim.getEvaluations();

        final double scale = 1e10;
        final MultivariateFunction funcScaled = new MultivariateFunction() {
View Full Code Here

Examples of org.apache.commons.math3.optimization.general.GaussNewtonOptimizer.optimize()

            public PointVectorValuePair optimize(int maxEval,
                                                 MultivariateDifferentiableVectorFunction f,
                                                 double[] target,
                                                 double[] weight,
                                                 double[] startPoint) {
                return gn.optimize(maxEval, f, target, weight, startPoint);
            }

            public int getMaxEvaluations() {
                return gn.getMaxEvaluations();
            }
View Full Code Here

Examples of org.apache.commons.math3.optimization.general.NonLinearConjugateGradientOptimizer.optimize()

                                                            new SimpleValueChecker(1.0e-10, 1.0e-10));
            public PointValuePair optimize(int maxEval,
                                           MultivariateDifferentiableFunction f,
                                           GoalType goalType,
                                           double[] startPoint) {
                return cg.optimize(maxEval, f, goalType, startPoint);
            }

            public int getMaxEvaluations() {
                return cg.getMaxEvaluations();
            }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.QueryTreeNode.optimize()

          if (preparedStmt.referencesSessionSchema(qt)) {
            if (foundInCache)
              ((GenericLanguageConnectionContext)lcc).removeStatement(this);
          }
         
          qt = qt.optimize();

          optimizeTime = getCurrentTimeMillis(lcc);

          // Statement logging if lcc.getLogStatementText() is true
          if (istream != null)
View Full Code Here

Examples of org.apache.hadoop.hive.ql.optimizer.Optimizer.optimize()

        opToSamplePruner);

    Optimizer optm = new Optimizer();
    optm.setPctx(pCtx);
    optm.initialize(conf);
    pCtx = optm.optimize();
    init(pCtx);
    qb = pCtx.getQB();

    // At this point we have the complete operator tree
    // from which we want to find the reduce operator
View Full Code Here

Examples of org.apache.hadoop.hive.ql.optimizer.physical.PhysicalOptimizer.optimize()

    PhysicalContext physicalContext = new PhysicalContext(conf,
        getParseContext(), ctx, rootTasks, fetchTask);
    PhysicalOptimizer physicalOptimizer = new PhysicalOptimizer(
        physicalContext, conf);
    physicalOptimizer.optimize();

    // For each operator, generate the counters if needed
    if (HiveConf.getBoolVar(conf, HiveConf.ConfVars.HIVEJOBPROGRESS)) {
      for (Task<? extends Serializable> rootTask : rootTasks) {
        generateCountersTask(rootTask);
View Full Code Here

Examples of org.apache.lucene.index.IndexModifier.optimize()

            }

            // Now index all the new conversations.
            long newestDate = indexConversations(conversationIDs, externalMetaData, writer, false);

            writer.optimize();

            // Done indexing so store a last modified date.
            if (newestDate != -1) {
                lastModified = newestDate;
                indexProperties.setProperty("lastModified", Long.toString(lastModified));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.