Skip to content

Conversation

@Lauenburg
Copy link
Contributor

While reviewing the public code, I found that the Ds update incorrectly uses Dy’s optimizer and scheduler.
Effect: Ds never updates. Dy steps twice per iteration and its LR decays twice. This can distort the seg-adversarial signal and weaken translation quality.

Current:

loss_Ds = self.update_netD(self.Ds, real_seg, self.image_pool['Ds'].query(fake_seg),
                           self.optimizer['Dy'], self.lr_scheduler['Dy'])

Fix:

loss_Ds = self.update_netD(self.Ds, real_seg, self.image_pool['Ds'].query(fake_seg),
                           self.optimizer['Ds'], self.lr_scheduler['Ds'])

@donglaiw donglaiw merged commit 7ec3284 into PytorchConnectomics:master Oct 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants