Skip to content

Commit

Permalink
fix type hint
Browse files Browse the repository at this point in the history
  • Loading branch information
kzkadc committed Oct 14, 2024
1 parent a027027 commit f9d63be
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ignite/metrics/clustering/silhouette_score.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from typing import Any, Callable, Union
from typing import Any, Callable, Union, Optional

import torch
from torch import Tensor
Expand Down Expand Up @@ -97,7 +97,7 @@ def __init__(
check_compute_fn: bool = True,
device: Union[str, torch.device] = torch.device("cpu"),
skip_unrolling: bool = False,
silhouette_kwargs: dict | None = None,
silhouette_kwargs: Optional[dict] = None,
) -> None:
try:
from sklearn.metrics import silhouette_score # noqa: F401
Expand Down

0 comments on commit f9d63be

Please sign in to comment.