class_docstr: labels of the dataset is optional
  
  here's the examples of loading the labels:
  
  :obj:`I`: ``DataProcessor(labels = ['positive', 'negative'])``
  
  :obj:`II`: ``DataProcessor(labels_path = 'datasets/labels.txt')``
  labels file should have label names separated by any blank characters, such as
  
  ..  code-block::
  
      positive neutral
      negative
  
  Args:
      labels (:obj:`Sequence[Any]`, optional): class labels of the dataset. Defaults to None.
      labels_path (:obj:`str`, optional): Defaults to None. If set and :obj:`labels` is None, load labels from :obj:`labels_path`.
class_docstr_tok: ["labels","of","the","dataset","is","optional","here","'s","the","examples","of","loading","the","labels",":",":","obj",":","`","I","`",":","``","DataProcessor","(","labels","=","[","'positive","'",",","'negative","'","]",")","``",":","obj",":","`","II","`",":","``","DataProcessor","(","labels_path","=","'datasets\/labels.txt","'",")","``","labels","file","should","have","label","names","separated","by","any","blank","characters",",","such","as","..","code-block",":",":","positive","neutral","negative","Args",":","labels","(",":","obj",":","`","Sequence","[","Any","]","`",",","optional",")",":","class","labels","of","the","dataset",".","Defaults","to","None",".","labels_path","(",":","obj",":","`","str","`",",","optional",")",":","Defaults","to","None",".","If","set","and",":","obj",":","`","labels","`","is","None",",","load","labels","from",":","obj",":","`","labels_path","`","."]
code: def label_mapping(self) -> Dict[Any, int]:
      if not hasattr(self, "_labels"):
          raise ValueError(
              "DataProcessor doesn't set labels or label_mapping yet"
          )
      return self._label_mapping
  
file_path: OpenPrompt/openprompt/data_utils/data_processor.py
imports: from typing import *
  from abc import abstractmethod
  from openprompt.data_utils.utils import InputExample
label_desc: Use image node_id 4 for calling the DataProcessor obj's underlying member method code with example usage: obj.label_mapping() and returns: self