fractal.core package

Subpackages

Submodules

fractal.core.launcher module

class fractal.core.launcher.Launcher(strategy_type: Type[BaseStrategy], params: BaseStrategyParams)[source]

Bases: object

Launcher is used to run strategies with different scenarios: - Single trajectory - Multiple trajectories - Scenario (multiple fractals in sliding window across the observations)

property last_created_instance: BaseStrategy | None
run_multiple_trajectories(observations: List[List[Observation]], debug: bool = False) List[StrategyResult][source]

Run the fractal for multiple trajectories. For simulation, we run the fractal for multiple Monte Carlo simulated trajectories.

Parameters:

observations – List of trajectories, where each trajectory is a list of observations.

Returns:

List of fractal results for each trajectory.

run_scenario(observations: List[Observation], window_size: int = 720, step_size: int = 24, debug: bool = False) List[StrategyResult][source]

Run the scenario (multiple fractals in sliding window across the observations).

run_strategy(observations: List[Observation], debug: bool = False) StrategyResult[source]

Run strategy for a single trajectory.

strategy_instance() BaseStrategy[source]

Get the copy of the strategy to avoid storing outdated states.

fractal.core.pipeline module

Module contents