pytorch / opacus

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

Fix BatchMemoryManager length #641

Closed lsc64 closed 1 month ago

lsc64 commented 3 months ago

Types of changes

Motivation and Context / Related issue

Fixes #640 by ceiling the number of batches.

How Has This Been Tested (if it applies)

Checklist

facebook-github-bot commented 3 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 3 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 3 months ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 month ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 month ago

@facebook-github-bot has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

lsc64 commented 1 month ago

Could you add this missing line back? The current version fails the lint test (https://app.circleci.com/pipelines/github/pytorch/opacus/3256/workflows/26b31f87-1e6e-4562-b070-59dc983bdf4e/jobs/18514?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-checks-link&utm_content=summary). Then I will approve the pr. Thx!

Sorry my styling constantly changed everything around. Files changed now shows only two changed lines, hope it works now!

facebook-github-bot commented 1 month ago

This pull request has been merged in pytorch/opacus@7d65ddf37565adf0fc11de7dab826d4e26a44704.