public class PerformanceMetrics extends Object
Modifier and Type | Method and Description |
---|---|
PerformanceMetric |
getBotIdle()
Time bot spends idle.
|
PerformanceMetric |
getBotResponse()
Time spent waiting for bot event handlers to complete for a single frame.
|
PerformanceMetric |
getClientIdle()
Time the main thread spends idle, waiting for the bot to finish processing frames.
|
PerformanceMetric |
getCommunicationListenToReceive()
Time spent waiting for a "frame ready" signal from BWAPI.
|
PerformanceMetric |
getCommunicationSendToReceive()
Time spent waiting for a response from BWAPI,
inclusive of the time spent sending the signal to BWAPI
and the time spent waiting for and receiving it.
|
PerformanceMetric |
getCommunicationSendToSent()
Time spent sending the "frame complete" signal to BWAPI.
|
PerformanceMetric |
getCopyingToBuffer()
Time spent copying game data from system pipe shared memory to a frame buffer.
|
PerformanceMetric |
getExcessSleep()
Time the main thread spends oversleeping its timeout target, potentially causing overtime frames.
|
PerformanceMetric |
getFlushSideEffects()
Time spent applying bot commands to the live frame.
|
PerformanceMetric |
getFrameBufferSize()
Number of frames backed up in the frame buffer, after enqueuing each frame (and not including the newest frame).
|
PerformanceMetric |
getFrameDurationReceiveToReceive()
Duration of a frame cycle originating at
the time when JBWAPI observes a new frame in shared memory.
|
PerformanceMetric |
getFrameDurationReceiveToSend()
Duration of the frame cycle steps measured by BWAPI,
from receiving a frame to BWAPI
to sending commands back
*exclusive* of the time spent sending commands back.
|
PerformanceMetric |
getFrameDurationReceiveToSent()
Duration of the frame cycle steps measured by BWAPI,
from receiving a frame to BWAPI
to sending commands back
*inclusive* of the time spent sending commands back.
|
PerformanceMetric |
getFramesBehind()
Number of frames behind real-time the bot is at the time it handles events.
|
PerformanceMetric |
getIntentionallyBlocking()
Time spent intentionally blocking on bot operation due to a full frame buffer.
|
PerformanceMetric |
getNumberOfEvents()
The number of events sent by BWAPI each frame.
|
PerformanceMetric |
getNumberOfEventsTimesDurationReceiveToSent()
The number of events sent by BWAPI each frame,
multiplied by the duration of time spent on that frame (receive-to-sent).
|
void |
reset()
Clears all tracked data and starts counting from a blank slate.
|
String |
toString() |
public PerformanceMetric getFrameDurationReceiveToSend()
public PerformanceMetric getFrameDurationReceiveToSent()
public PerformanceMetric getFrameDurationReceiveToReceive()
public PerformanceMetric getCopyingToBuffer()
public PerformanceMetric getIntentionallyBlocking()
public PerformanceMetric getFrameBufferSize()
public PerformanceMetric getFramesBehind()
public PerformanceMetric getFlushSideEffects()
public PerformanceMetric getBotResponse()
public PerformanceMetric getCommunicationSendToReceive()
public PerformanceMetric getCommunicationSendToSent()
public PerformanceMetric getCommunicationListenToReceive()
public PerformanceMetric getBotIdle()
public PerformanceMetric getClientIdle()
public PerformanceMetric getExcessSleep()
public PerformanceMetric getNumberOfEvents()
public PerformanceMetric getNumberOfEventsTimesDurationReceiveToSent()
public void reset()
Copyright © 2022. All rights reserved.