Skip to content

Commit c4ab0b7

Browse files
committed
Change backend parameter into solver_backend
1 parent 9f5b9db commit c4ab0b7

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

monai/transforms/intensity/array.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2593,30 +2593,31 @@ class UltrasoundConfidenceMapTransform(Transform):
25932593
beta (float, optional): Beta parameter. Defaults to 90.0.
25942594
gamma (float, optional): Gamma parameter. Defaults to 0.05.
25952595
mode (str, optional): 'RF' or 'B' mode data. Defaults to 'B'.
2596-
sink_mode (str, optional): Sink mode. Defaults to 'all'. If 'mask' is selected, a mask must be when calling the transform.
2596+
sink_mode (str, optional): Sink mode. Defaults to 'all'. If 'mask' is selected, a mask must be when calling the transform. Can be one of 'all', 'mid', 'min', 'mask'.
2597+
backend (str, optional): Backend to use. Defaults to 'scipy'. Can be one of 'scipy', 'octave'.
25972598
"""
25982599

25992600
def __init__(
26002601
self,
26012602
alpha: float = 2.0,
26022603
beta: float = 90.0,
26032604
gamma: float = 0.05,
2604-
mode: Literal["RF", "B"] = "B",
2605-
sink_mode: Literal["all", "mid", "min", "mask"] = "all",
2606-
backend: Literal["scipy", "octave"] = "scipy",
2605+
mode = "B",
2606+
sink_mode = "all",
2607+
solver_backend = "scipy",
26072608
) -> None:
26082609
self.alpha = alpha
26092610
self.beta = beta
26102611
self.gamma = gamma
26112612
self.mode = mode
26122613
self.sink_mode = sink_mode
2613-
self.backend = backend
2614+
self.solver_backend = solver_backend
26142615

26152616
if self.mode not in ["B", "RF"]:
26162617
raise ValueError(f"Unknown mode: {self.mode}. Supported modes are 'B' and 'RF'.")
26172618

2618-
if self.backend not in ["scipy", "octave"]:
2619-
raise ValueError(f"Unknown backend: {self.backend}. Supported modes are 'scipy' and 'octave'.")
2619+
if self.solver_backend not in ["scipy", "octave"]:
2620+
raise ValueError(f"Unknown solver backend: {self.solver_backend}. Supported modes are 'scipy' and 'octave'.")
26202621

26212622
if self.sink_mode not in ["all", "mid", "min", "mask"]:
26222623
raise ValueError(f"Unknown sink mode: {self.sink_mode}. Supported modes are 'all', 'mid', 'min' and 'mask'.")

0 commit comments

Comments
 (0)