code: def clone(self) -> PivotedCholesky:
      fields = {}
      for name in ("tril", "perm", "diag"):
          obj = getattr(self, name)
          if obj is not None:
              fields[name] = obj.clone()
      return type(self)(step=self.step, **fields)
  
file_path: botorch/botorch/utils/probability/linalg.py
imports: from __future__ import annotations
  from dataclasses import dataclass, InitVar
  from itertools import chain
  from typing import Any, Optional, Sequence
  import torch
  from botorch.utils.probability.utils import swap_along_dim_
  from linear_operator.utils.errors import NotPSDError
  from torch import LongTensor, Tensor
  from torch.nn.functional import pad
label_desc: Use image node_id 8 for calling the PivotedCholesky obj's underlying member method code with example usage: obj.clone() and returns: type