pytorch / opacus

Training PyTorch models with differential privacy
https://opacus.ai
Apache License 2.0
1.67k stars 332 forks source link

Conv3d test fix #527

Closed ffuuugor closed 1 year ago

ffuuugor commented 1 year ago

Conv3d grad sample test is failing currently: CircleCI

This is most likely due to a difference in unfold3d method between opacus and EW implementations.

Opacus:

if dilation != (1, 1, 1):
    tensor = filter_dilated_rows(tensor, dilation, dilated_kernel_size, kernel_size)

EW:

if dilation != (1, 1, 1):
    raise NotImplementedError(f"dilation={dilation} not supported.")

As dilation other than 1 is not supported under any conditions with EW, I've fixed thenis_ew_compatible flag.

PS: @ashkan-software do we have a github issue to update EW's unfold3d with the recent updates you made?

facebook-github-bot commented 1 year ago

@ffuuugor has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 year ago

@ffuuugor has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 1 year ago

@ffuuugor has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.