src/transformers/models/yoso/modeling_yoso.py/YosoPreTrainedModel/_set_gradient_checkpointing
class YosoPreTrainedModel:    def _set_gradient_checkpointing(self, module, value=False):
        if isinstance(module, YosoEncoder):
            module.gradient_checkpointing = value