MCPcopy Create free account
hub / github.com/AdaCompNUS/summit / CallBack

Class CallBack

PythonAPI/util/performance_benchmark.py:139–151  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

137
138
139class CallBack(object):
140 def __init__(self):
141 self._lock = threading.Lock()
142 self._pygame_clock = pygame.time.Clock()
143 self._current_fps = 0
144
145 def __call__(self, data):
146 self._pygame_clock.tick()
147 self._current_fps = self._pygame_clock.get_fps()
148
149 def get_fps(self):
150 with self._lock:
151 return self._current_fps
152
153
154def create_environment(world, sensors, n_vehicles, n_walkers, spawn_points, client):

Callers 1

create_environmentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected