blocksnet.method.land_use_optimizer

Functions

log_execution_time(func)

Classes

Indicator(fsi_min, fsi_max, gsi_min, gsi_max)

LandUseOptimizer(*, city_model[, verbose, ...])

class blocksnet.method.land_use_optimizer.Indicator(fsi_min, fsi_max, gsi_min, gsi_max)[source]

Bases: object

blocksnet.method.land_use_optimizer.log_execution_time(func)[source]
class blocksnet.method.land_use_optimizer.LandUseOptimizer(*, city_model: City, verbose: bool = True, annealing_rate: float = 0.5, max_iter: int = 50)[source]

Bases: BaseMethod

annealing_rate: float
max_iter: int
property annealing_optimizer
to_gdf(blocks: dict[int, blocksnet.models.land_use.LandUse])[source]
calculate(blocks: list[blocksnet.models.city.Block], service_types: dict[str, float], lu_shares: dict[blocksnet.models.land_use.LandUse, float], generations: int = 10, parents: int = 4, solutions: int = 8) tuple[dict[int, blocksnet.models.land_use.LandUse], tuple[float, float], pygad.pygad.GA][source]

Main calculation method that should be overridden in child class.

Parameters:
  • *args (tuple) – Variable length argument list.

  • **kwargs (dict) – Arbitrary keyword arguments.

Raises:

NotImplementedError – If the method is not implemented in the child class.

model_computed_fields: ClassVar[Dict[str, ComputedFieldInfo]] = {}

A dictionary of computed field names and their corresponding ComputedFieldInfo objects.