src/transformers/models/speech_to_text/modeling_speech_to_text.py/Speech2TextPreTrainedModel/_set_gradient_checkpointing
class Speech2TextPreTrainedModel:    def _set_gradient_checkpointing(self, module, value=False):
        if isinstance(module, (Speech2TextDecoder, Speech2TextEncoder)):
            module.gradient_checkpointing = value