code: def getLatency(self, instId: int) -> float:
          
          if len(self.clientAvgReqLatencies) == 0:
              return 0.0
          return self.clientAvgReqLatencies[instId].get_avg_latency()
docs: Return a dict with client identifier as a key and calculated latency as a value