Skip to content

Commit

Permalink
Fix var names
Browse files Browse the repository at this point in the history
  • Loading branch information
bhky committed Aug 17, 2024
1 parent 25aedb6 commit 6f0d21a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions opennsfw2/_inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,10 @@ def _predict_from_image_handles_in_batches(
"""
prediction_batches: List[Any] = []
for i in range(0, len(image_handles), batch_size):
path_batch = image_handles[i: i + batch_size]
handle_batch = image_handles[i: i + batch_size]
image_batch = [
preprocess_image(_load_pil_image(path), preprocessing)
for path in path_batch
preprocess_image(_load_pil_image(handle), preprocessing)
for handle in handle_batch
]
prediction_batches.append(model_(np.array(image_batch)))
predictions: NDFloat32Array = np.concatenate(prediction_batches, axis=0)
Expand Down

0 comments on commit 6f0d21a

Please sign in to comment.