Events
simulate()
returns an Iterator
of Event objects. The user can understand what happened
during the simulation run from these events, and if desired, compute metrics,
e.g. the waiting times for the requests and the detours suffered by them.
- class Event[source]
The base event class. Must hold a timestamp.
event = { "event_type": "Event", "timestamp": ..., }
- class RequestSubmissionEvent[source]
Submission of a request with specific spatio-temporal constraints to the system.
request_submission_event = { "event_type": "RequestSubmissionEvent", "timestamp": ..., "request_id": ..., "origin": ..., "destination": ..., "pickup_timewindow_min": ..., "pickup_timewindow_max": ..., "delivery_timewindow_min": ..., "delivery_timewindow_max": ..., }
- class RequestAcceptanceEvent[source]
Commitment of the system to fulfil a request given the returned spatio-temporal constraints.
request_acceptance_event = { "event_type": "RequestAcceptanceEvent", "timestamp": ..., "request_id": ..., "origin": ..., "destination": ..., "pickup_timewindow_min": ..., "pickup_timewindow_max": ..., "delivery_timewindow_min": ..., "delivery_timewindow_max": ..., }
- class RequestRejectionEvent[source]
Inability of the system to fulfil a request.
request_rejection_event = { "event_type": "RequestRejectionEvent", "timestamp": ..., "request_id": ..., }
- class PickupEvent[source]
Successful pick-up action.
pickup_event = { "event_type": "PickupEvent", "timestamp": ..., "request_id": ..., "vehicle_id": ..., }
- class DeliveryEvent[source]
Successful drop-off action.
delivery_event = { "event_type": "DeliveryEvent", "timestamp": ..., "request_id": ..., "vehicle_id": ..., }
- class InternalEvent[source]
Successful internal action.
internal_event = { "event_type": "InternalEvent", "timestamp": ..., "vehicle_id": ..., }
- class VehicleStateBeginEvent[source]
vehicle_state_begin_event = { "event_type": "VehicleStateBeginEvent", "timestamp": ..., "vehicle_id": ..., "location": ..., "request_id": -100, }
- class VehicleStateEndEvent[source]
vehicle_state_end_event = { "event_type": "VehicleStateEndEvent", "timestamp": ..., "vehicle_id": ..., "location": ..., "request_id": -200, }
- RequestEvent
Emitted when a
TransportationRequest
is handled.alias of
RequestSubmissionEvent
|RequestAcceptanceEvent
|RequestRejectionEvent
- StopEvent
Emitted when a
Stop
is serviced.alias of
InternalEvent
|PickupEvent
|DeliveryEvent
- RequestResponse
Emitted when a
TransportationRequest
is handled.alias of
RequestAcceptanceEvent
|RequestRejectionEvent