code: def clone(self):
      import copy
  
      if self.is_multi_label:
          data = [
              (
                  torch.clone(
                      d[PytorchTextClassificationDataset.INDEX_TEXT]
                  ),
                  d[
                      PytorchTextClassificationDataset.INDEX_LABEL
                  ].copy(),
              )
              for d in self.data
          ]
      else:
          data = [
              (
                  torch.clone(
                      d[PytorchTextClassificationDataset.INDEX_TEXT]
                  ),
                  np.copy(
                      d[PytorchTextClassificationDataset.INDEX_LABEL]
                  ),
              )
              for d in self.data
          ]
  
      dataset = self
      while hasattr(dataset, "dataset"):
          dataset = dataset.dataset
  
      if dataset.track_target_labels:
          target_labels = None
      else:
          target_labels = np.copy(dataset.target_labels)
  
      return PytorchTextClassificationDataset(
          data,
          copy.deepcopy(self.vocab),
          multi_label=self.is_multi_label,
          target_labels=target_labels,
      )
  
imports: import torch
  import numpy
  from abc import ABC, abstractmethod
  from scipy.sparse import csr_matrix
  from small_text.base import LABEL_UNLABELED
  from small_text.data import DatasetView
  from small_text.data.datasets import check_size, check_target_labels, get_updated_target_labels
  from small_text.data.exceptions import UnsupportedOperationException
  from small_text.utils.annotations import experimental
  from small_text.utils.labels import csr_to_list, get_num_labels, list_to_csr
label_desc: Use image node_id 1 for calling the PytorchTextClassificationDatasetView obj's underlying member method code with example usage: obj.clone() and returns: PytorchTextClassificationDataset