class_docstr: Configuration options for the training of the Profet meta-model.
class_docstr_tok: ["Configuration","options","for","the","training","of","the","Profet","meta-model","."]
docstr: Save the meta-model for the task at the given path.
  
  Parameters
  ----------
  checkpoint_file : Union[str, Path]
      Path where the model should be saved
  network : Any
      The network
  h : np.ndarray
      The embedding vector
docstr_tok: ["Save","the","meta-model","for","the","task","at","the","given","path",".","Parameters","--","--","--","--","--","checkpoint_file",":","Union","[","str",",","Path","]","Path","where","the","model","should","be","saved","network",":","Any","The","network","h",":","np.ndarray","The","embedding","vector"]
code: def save_task_network(
      self,
      checkpoint_file: Union[str, Path],
      network: Any,
      h: np.ndarray,
  ) -> None:
      """Save the meta-model for the task at the given path.
  
      Parameters
      ----------
      checkpoint_file : Union[str, Path]
          Path where the model should be saved
      network : Any
          The network
      h : np.ndarray
          The embedding vector
      """
      checkpoint_file = Path(checkpoint_file)
      state = dict(
          benchmark=self.benchmark,
          network=network.state_dict(),
          size=list(network.parameters())[0].size()[1],
          h=h.tolist(),
      )
  
      tmp_file = checkpoint_file.with_suffix(".tmp")
      with open(tmp_file, "wb") as file:
          pickle.dump(state, file, protocol=pickle.DEFAULT_PROTOCOL)
      tmp_file.rename(checkpoint_file)
  
imports: import json
  import pickle
  import warnings
  from abc import ABC
  from copy import deepcopy
  from dataclasses import dataclass
  from logging import getLogger
  from pathlib import Path
  from typing import Any, Callable, ClassVar, Optional, Tuple, Union
  import numpy
label_desc: Use image node_id 9 for calling the MetaModelConfig obj's underlying member method code with example usage: obj.save_task_network(checkpoint_file, network, h) without return types