class_docstr: Cache the distillation labels on disk.
  Under each label will be saved as a file named `{uid}.pkl` under `cache_folder`.
class_docstr_tok: ["Cache","the","distillation","labels","on","disk",".","Under","each","label","will","be","saved","as","a","file","named","`","{","uid","}",".pkl","`","under","`","cache_folder","`","."]
code: def save_checkpoint(self, checkpoint_folder: str | PathLike):
      root_path = Path(checkpoint_folder).absolute()
      if root_path != self._cache_folder:
          shutil.copytree(
              self._cache_folder,
              root_path,
              copy_function=shutil.copy2,
              dirs_exist_ok=True,
          )
      with Path(root_path / SETTING_FILENAME).open(mode="w") as f:
          json_tricks.dump(self._uid2filename, f, indent=4)
  
imports: from __future__ import annotations
  import logging
  import os
  from os import PathLike
  from pathlib import Path
  import shutil
  import tempfile
  from typing import Any, Dict, List, Literal
  import json_tricks
  from .utils import pickle_dump, pickle_load
label_desc: Use image node_id 8 for calling the FileStorage obj's underlying member method code with example usage: obj.save_checkpoint(checkpoint_folder) without return types