Skip to content

Commit cc0c951

Browse files
committed
Fix PerceptualLoss enum references and docstrings
1 parent 96ea131 commit cc0c951

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

monai/losses/perceptual.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class PerceptualLoss(nn.Module):
7676
def __init__(
7777
self,
7878
spatial_dims: int,
79-
network_type: str = PercetualNetworkType.alex,
79+
network_type: str = PerceptualNetworkType.alex,
8080
is_fake_3d: bool = True,
8181
fake_3d_ratio: float = 0.5,
8282
cache_dir: str | None = None,
@@ -99,10 +99,10 @@ def __init__(
9999
if channel_wise and "medicalnet_" not in network_type:
100100
raise ValueError("Channel-wise loss is only compatible with MedicalNet networks.")
101101

102-
if network_type.lower() not in list(PercetualNetworkType):
102+
if network_type.lower() not in list(PerceptualNetworkType):
103103
raise ValueError(
104104
"Unrecognised criterion entered for Adversarial Loss. Must be one in: %s"
105-
% ", ".join(PercetualNetworkType)
105+
% ", ".join(PerceptualNetworkType)
106106
)
107107

108108
if cache_dir:

0 commit comments

Comments
 (0)