Schedule

Submodules

Schedule config

class fleetrl.utils.schedule.schedule_config.ScheduleConfig(schedule_type, env_config)[source]

Bases: object

Statistical configurations for the schedule generator. Mean and standard deviation values are specified for each metric, allowing for a distributional and probabilistic generation approach.

class fleetrl.utils.schedule.schedule_config.ScheduleType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: Enum

Caretaker = 2
Custom = 4
Delivery = 1
Utility = 3

Schedule generator

class fleetrl.utils.schedule.schedule_generator.ScheduleGenerator(env_config, schedule_type=ScheduleType.Delivery, vehicle_id='0')[source]

Bases: object

Probabilistic schedule generator. Loops through each 15 min timeslot in the yearly dataframe and generates a row entry. The format is kept similar to emobpy to enable compatability and ease of use.

generate_caretaker()[source]

Caretaker generator. Lunch break, operations on Sunday, chance for emergency trips at night :return: pd.DataFrame of the schedule

generate_custom()[source]

Custom schedule generator. Saturdays operations occur but at reduced levels, no operations on Sunday. :return: pd.DataFrame of the schedule

generate_delivery()[source]

Delivery schedule generator. Saturdays operations occur but at reduced levels, no operations on Sunday. :return: pd.DataFrame of the schedule

generate_schedule()[source]

This method chooses the right generation method depending on the use-case. Returns the schedule dataframe.

Returns:

pd.DataFrame of the schedule

generate_utility()[source]

Utility generation. Chance for operations on Sunday. :return: pd.DataFrame of the schedule.