Skip to content

Commit

Permalink
comment
Browse files Browse the repository at this point in the history
  • Loading branch information
BlackSamorez committed Feb 18, 2024
1 parent 672a665 commit 4b08a7e
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

@contextmanager
def optimize_for_training():
"""Use this context manager during model initialization (e.g. `.from_pretrained(...)`) to select inference kernels optimized for larger batch sizes"""
global _OPTIMIZE_FOR_TRAINING
_OPTIMIZE_FOR_TRAINING = True
try:
Expand Down

0 comments on commit 4b08a7e

Please sign in to comment.