Formatting

This commit is contained in:
Nicolas Mowen 2025-11-09 07:27:33 -07:00
parent 8700332a44
commit a242c31b9e

View File

@ -227,7 +227,9 @@ class CustomStateClassificationProcessor(RealTimeProcessorApi):
self.tensor_output_details[0]["index"] self.tensor_output_details[0]["index"]
)[0] )[0]
probs = res / res.sum(axis=0) probs = res / res.sum(axis=0)
logger.debug(f"{self.model_config.name} Ran state classification with probabilities: {probs}") logger.debug(
f"{self.model_config.name} Ran state classification with probabilities: {probs}"
)
best_id = np.argmax(probs) best_id = np.argmax(probs)
score = round(probs[best_id], 2) score = round(probs[best_id], 2)
self.__update_metrics(datetime.datetime.now().timestamp() - now) self.__update_metrics(datetime.datetime.now().timestamp() - now)
@ -456,7 +458,9 @@ class CustomObjectClassificationProcessor(RealTimeProcessorApi):
self.tensor_output_details[0]["index"] self.tensor_output_details[0]["index"]
)[0] )[0]
probs = res / res.sum(axis=0) probs = res / res.sum(axis=0)
logger.debug(f"{self.model_config.name} Ran object classification with probabilities: {probs}") logger.debug(
f"{self.model_config.name} Ran object classification with probabilities: {probs}"
)
best_id = np.argmax(probs) best_id = np.argmax(probs)
score = round(probs[best_id], 2) score = round(probs[best_id], 2)
self.__update_metrics(datetime.datetime.now().timestamp() - now) self.__update_metrics(datetime.datetime.now().timestamp() - now)