Skip to content

Commit

Permalink
Change np.float_ to np.float64 (#1561)
Browse files Browse the repository at this point in the history
  • Loading branch information
philippmwirth authored Jun 24, 2024
1 parent ffe5b56 commit f9e353c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lightly/api/api_workflow_selection.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def _parse_active_learning_scores(scores: Union[np.ndarray, List]):

class _SelectionMixin:
def upload_scores(
self, al_scores: Dict[str, NDArray[np.float_]], query_tag_id: str
self, al_scores: Dict[str, NDArray[np.float64]], query_tag_id: str
) -> None:
"""Uploads active learning scores for a tag.
Expand Down
4 changes: 2 additions & 2 deletions lightly/embedding/embedding.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def embed(
self,
dataloader: DataLoader[LightlyDataset],
device: Optional[torch.device] = None,
) -> Tuple[NDArray[np.float_], List[int], List[str]]:
) -> Tuple[NDArray[np.float64], List[int], List[str]]:
"""Embeds images in a vector space.
Args:
Expand Down Expand Up @@ -114,7 +114,7 @@ def embed(
pbar = tqdm(total=len(dataset), unit="imgs")

efficiency = 0.0
embeddings: List[NDArray[np.float_]] = []
embeddings: List[NDArray[np.float64]] = []
labels: List[int] = []
with torch.no_grad():
start_timepoint = time.time()
Expand Down

0 comments on commit f9e353c

Please sign in to comment.