Skip to content

Commit 90c5d95

Browse files
KumoLiuvgrau98
authored andcommitted
Fix typo. ### Types of changes <!--- Put an `x` in all the boxes that apply, and remove the not applicable items --> - [x] Non-breaking change (fix or new feature that would not break existing functionality). - [ ] Breaking change (fix or new feature that would cause existing functionality to change). - [ ] New tests added to cover the changes. - [ ] Integration tests passed locally by running `./runtests.sh -f -u --net --coverage`. - [ ] Quick tests passed locally by running `./runtests.sh --quick --unittests --disttests`. - [ ] In-line docstrings updated. - [ ] Documentation updated, tested `make html` command in the `docs/` folder. --------- Signed-off-by: YunLiu <[email protected]>
1 parent e7e07a9 commit 90c5d95

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

monai/metrics/hausdorff_distance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def compute_hausdorff_distance(
190190
y[b, c],
191191
distance_metric=distance_metric,
192192
spacing=spacing_list[b],
193-
symetric=not directed,
193+
symmetric=not directed,
194194
class_index=c,
195195
)
196196
percentile_distances = [_compute_percentile_hausdorff_distance(d, percentile) for d in distances]

monai/metrics/surface_dice.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ def compute_surface_dice(
253253
distance_metric=distance_metric,
254254
spacing=spacing_list[b],
255255
use_subvoxels=use_subvoxels,
256-
symetric=True,
256+
symmetric=True,
257257
class_index=c,
258258
)
259259
boundary_correct: int | torch.Tensor | float

monai/metrics/surface_distance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ def compute_average_surface_distance(
177177
y[b, c],
178178
distance_metric=distance_metric,
179179
spacing=spacing_list[b],
180-
symetric=symmetric,
180+
symmetric=symmetric,
181181
class_index=c,
182182
)
183183
surface_distance = torch.cat(distances)

monai/metrics/utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ def get_edge_surface_distance(
295295
distance_metric: str = "euclidean",
296296
spacing: int | float | np.ndarray | Sequence[int | float] | None = None,
297297
use_subvoxels: bool = False,
298-
symetric: bool = False,
298+
symmetric: bool = False,
299299
class_index: int = -1,
300300
) -> tuple[
301301
tuple[torch.Tensor, torch.Tensor],
@@ -314,7 +314,7 @@ def get_edge_surface_distance(
314314
See :py:func:`monai.metrics.utils.get_surface_distance`.
315315
use_subvoxels: whether to use subvoxel resolution (using the spacing).
316316
This will return the areas of the edges.
317-
symetric: whether to compute the surface distance from `y_pred` to `y` and from `y` to `y_pred`.
317+
symmetric: whether to compute the surface distance from `y_pred` to `y` and from `y` to `y_pred`.
318318
class_index: The class-index used for context when warning about empty ground truth or prediction.
319319
320320
Returns:
@@ -338,7 +338,7 @@ def get_edge_surface_distance(
338338
" this may result in nan/inf distance."
339339
)
340340
distances: tuple[torch.Tensor, torch.Tensor] | tuple[torch.Tensor]
341-
if symetric:
341+
if symmetric:
342342
distances = (
343343
get_surface_distance(edges_pred, edges_gt, distance_metric, spacing),
344344
get_surface_distance(edges_gt, edges_pred, distance_metric, spacing),

0 commit comments

Comments
 (0)