Skip to content

Commit

Permalink
update float and int types for slide coords and probs
Browse files Browse the repository at this point in the history
Use np.floating and np.integer.
  • Loading branch information
kaczmarj authored Jul 9, 2024
1 parent 7a867ce commit 385ce1f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wsinfer/modellib/run_inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ def run_inference(

# Store the coordinates and model probabiltiies of each patch in this slide.
# This lets us know where the probabiltiies map to in the slide.
slide_coords: list[npt.NDArray[np.int_]] = []
slide_probs: list[npt.NDArray[np.float_]] = []
slide_coords: list[npt.NDArray[np.integer]] = []
slide_probs: list[npt.NDArray[np.floating]] = []
for batch_imgs, batch_coords in tqdm.tqdm(loader):
assert batch_imgs.shape[0] == batch_coords.shape[0], "length mismatch"
with torch.no_grad():
Expand Down

0 comments on commit 385ce1f

Please sign in to comment.