Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove <= 2.0 version checks #800

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Apr 25, 2024

  1. remove <= 2.0 version checks

    Summary:
    # Context
    Part of effort to make TorchTNT OSS compliant.
    
    TorchTNT uses latest pytorch apis. Sometimes these are only available in nightlies. When that's the case, users in OSS using a stable pytorch release will see import errors when they use TorchTNT. This can be guarded against by importing conditionally, only when the compatible pytorch version is detected in the environment.
    
    We have plenty of these checks already. However, at the same time we don't want to bload TNT with too many of these version checks everywhere. Currently we have various version checks for Pytorch 1.0.
    
    I propose to make Pytorch 2.0+ a hard dependency for TorchTNT going forward. This will
    * remove existing version check bloat in TNT
    * force users to use latest features from pytorch
    And Pytorch 2.0 is documented to be 100% backwards compatible, so no bugs or errors should show up
    
    # This Diff
    
    Removes all the Pytorch version checks below 2.0 in various places of the codebase, and all the helper functions which check for version
    
    Differential Revision: D56446353
    JKSenthil authored and facebook-github-bot committed Apr 25, 2024
    Configuration menu
    Copy the full SHA
    b74f240 View commit details
    Browse the repository at this point in the history