experimental_experiment.xoptim.order_optim

class experimental_experiment.xoptim.order_optim.OrderAlgorithm(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Defines the possible order algorithm.

  • NONE: does not change anything

  • RANDOM: random order

class experimental_experiment.xoptim.order_optim.OrderOptimization(builder: GraphBuilder, algorithm: OrderAlgorithm = OrderAlgorithm.NONE, verbose: int = 0)[source]

Optimizes the order of computation.

Parameters:
  • builder – GraphBuilder holding the model

  • algorithm – to apply

  • verbose – verbosity

optimize() List[Dict[str, Any]][source]

Optimizes the model inplace. It optimizes the model in the builder itself by switching nodes.

random_order()[source]

Moves nodes by random.