Optimizer

class compas_cem.optimization.Optimizer(**kwargs)[source]

Bases: Data

An object that modifies a form diagram to meet multiple constraints.

Methods

add_constraint

Adds a goal constraint.

add_parameter

Adds a parameter to the optimization problem.

check_optimization_sanity

Verify the optimization problem is in its sane mind.

gradient_func

The objective function to calculate gradients from.

number_of_constraints

The number of constraints added to the optimizer.

number_of_parameters

The number of optimization parameters.

objective_func

The objective function to minimize.

optimization_bounds

Creates optimization bounds array.

optimization_parameters

Creates optimization paremeters array.

remove_constraint

Removes a constraint from the optimizer.

remove_parameter

Removes an optimization parameter.

solve

Solve a constrained form-finding problem using gradient-based optimization.

Inherited Methods

ToString

Converts the instance to a string.

copy

Make an independent copy of the data object.

from_data

Construct an object of this type from the provided data.

from_json

Construct an object from serialized data contained in a JSON file.

from_jsonstring

Construct an object from serialized data contained in a JSON string.

sha256

Compute a hash of the data for comparison during version control using the sha256 algorithm.

to_data

Convert an object to its native data representation.

to_json

Serialize the data representation of an object to a JSON file.

to_jsonstring

Serialize the data representation of an object to a JSON string.

validate_data

Validate the object's data against its data schema.

validate_json

Validate the object's data against its json schema.