mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-12-06 13:34:13 +03:00
fix format by using ruff instead of black
This commit is contained in:
parent
ec1e074c08
commit
d1aa07fcd1
@ -272,9 +272,7 @@ class EdgeTpuTfl(DetectionApi):
|
|||||||
) # initialize zero results
|
) # initialize zero results
|
||||||
scores_output_quantized = self.interpreter.get_tensor(
|
scores_output_quantized = self.interpreter.get_tensor(
|
||||||
self.scores_tensor_index
|
self.scores_tensor_index
|
||||||
)[
|
)[0] # (2100, NC)
|
||||||
0
|
|
||||||
] # (2100, NC)
|
|
||||||
max_scores_quantized = np.max(
|
max_scores_quantized = np.max(
|
||||||
scores_output_quantized, axis=1
|
scores_output_quantized, axis=1
|
||||||
) # (2100,)
|
) # (2100,)
|
||||||
@ -293,9 +291,7 @@ class EdgeTpuTfl(DetectionApi):
|
|||||||
# remove candidates with probabilities < threshold
|
# remove candidates with probabilities < threshold
|
||||||
boxes_output_quantized_filtered = (
|
boxes_output_quantized_filtered = (
|
||||||
self.interpreter.get_tensor(self.boxes_tensor_index)[0]
|
self.interpreter.get_tensor(self.boxes_tensor_index)[0]
|
||||||
)[
|
)[mask] # (N, 64)
|
||||||
mask
|
|
||||||
] # (N, 64)
|
|
||||||
boxes_output_filtered = (
|
boxes_output_filtered = (
|
||||||
boxes_output_quantized_filtered.astype(np.float32)
|
boxes_output_quantized_filtered.astype(np.float32)
|
||||||
- self.boxes_zero_point
|
- self.boxes_zero_point
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user