code: def copy_par_file(
      par_file: tp.Union[str, Path], folder: tp.Union[str, Path]
  ) -> Path:
      """Copy the par (or xar) file in the folder
  
      Parameter
      ---------
      par_file: str/Path
          Par file generated by buck
      folder: str/Path
          folder where the par file must be copied
  
      Returns
      -------
      Path
          Path of the copied .par file
      """
      par_file = Path(par_file).expanduser().absolute()
      folder = Path(folder).expanduser().absolute()
      folder.mkdir(parents=True, exist_ok=True)
      dst_name = folder / par_file.name
      shutil.copy2(par_file, dst_name)
      return dst_name
  
imports: import contextlib
  import io
  import itertools
  import os
  import pickle
  import select
  import shutil
  import subprocess
  import sys
  import tarfile
  import typing
  from pathlib import Path
  import cloudpickle
label_desc: Use image node_id 4 for calling a global function with example usage: copy_par_file(par_file, folder) and returns: dst_name