class_docstr: Support TIMM image backbones.
  Refer to https://github.com/rwightman/pytorch-image-models
docstr: Save TIMM image model configs to a local file.
  
  Parameters
  ----------
  config_path:
      A file to where the config is written to.
docstr_tok: ["Save","TIMM","image","model","configs","to","a","local","file",".","Parameters","--","--","--","--","--","config_path",":","A","file","to","where","the","config","is","written","to","."]
code: def dump_config(
      self,
      config_path: str,
  ):
      """
      Save TIMM image model configs to a local file.
  
      Parameters
      ----------
      config_path:
          A file to where the config is written to.
      """
      from ..utils import filter_timm_pretrained_cfg
  
      config = {}
      pretrained_cfg = filter_timm_pretrained_cfg(
          self.config, remove_source=True, remove_null=True
      )
      # set some values at root config level
      config["architecture"] = pretrained_cfg.pop("architecture")
      config["num_classes"] = self.num_classes
      config["num_features"] = self.out_features
  
      global_pool_type = getattr(self, "global_pool", None)
      if isinstance(global_pool_type, str) and global_pool_type:
          config["global_pool"] = global_pool_type
  
      config["pretrained_cfg"] = pretrained_cfg
  
      with open(config_path, "w") as f:
          json.dump(config, f, indent=2)
          logger.info(f"Timm config saved to {config_path}.")
  
imports: import json
  import logging
  import os
  from typing import Dict, List, Optional
  import torch
  from timm import create_model
  from timm.layers.linear import Linear
  from torch import nn
  from ..constants import AUTOMM, COLUMN, COLUMN_FEATURES, FEATURES, IMAGE, IMAGE_VALID_NUM, LABEL, LOGITS, MASKS
  from .utils import assign_layer_ids, get_column_features, get_model_head
label_desc: Use image node_id 12 for calling the TimmAutoModelForImagePrediction obj's underlying member method code with example usage: obj.dump_config(config_path) without return types