code: def on_save_checkpoint(self, checkpoint: Dict[str, Any]):
      checkpoint["active_dataset"] = self.active_dataset.state_dict()
  
imports: import sys
  import types
  import warnings
  from collections.abc import Sequence
  from typing import Dict, Any, Optional
  import numpy
  import structlog
  import torch
  from pytorch_lightning import Trainer, Callback, LightningDataModule, LightningModule
  from pytorch_lightning.accelerators import CUDAAccelerator
  from torch.utils.data import DataLoader
  from tqdm import tqdm
  from baal.active import ActiveLearningDataset
  from baal.active.heuristics import heuristics
  from baal.modelwrapper import mc_inference
  from baal.utils.cuda_utils import to_cuda
  from baal.utils.iterutils import map_on_tensor
label_desc: Use image node_id 4 for calling the BaaLDataModule obj's underlying member method code with example usage: obj.on_save_checkpoint(checkpoint) without return types