Skip to content

Commit 3a2ffc5

Browse files
committed
remove step_ratio variable
Signed-off-by: ytl0623 <[email protected]>
1 parent b96ec40 commit 3a2ffc5

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

monai/networks/schedulers/ddpm.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,6 @@ def set_timesteps(self, num_inference_steps: int, device: str | torch.device | N
122122
)
123123

124124
self.num_inference_steps = num_inference_steps
125-
step_ratio = self.num_train_timesteps // self.num_inference_steps
126125
# creates integer timesteps by multiplying by ratio
127126
# casting to int to avoid issues when num_inference_step is power of 3
128127
timesteps = np.linspace(self.num_train_timesteps - 1, 0, num_inference_steps).round().astype(np.int64)

0 commit comments

Comments
 (0)