keras/src/backend/common/variables.py/AutocastScope/__enter__
class AutocastScope:    def __enter__(self):
        self.original_scope = get_autocast_scope()
        global_state.set_global_attribute("autocast_scope", self)