class_docstr: A Spark RDD counterpart.
  
  PrivateRDD guarantees that only data that has been aggregated 
  in a DP manner, using no more than the specified privacy 
  budget, can be extracted from it through its API.
  
  PrivateRDD keeps a `privacy_id` for each element
  in order to guarantee correct DP computations.
docstr: A Spark map equivalent.
  
  Keeps track of privacy_id for each element.
  The output PrivateRDD has the same BudgetAccountant as this one.
docstr_tok: ["A","Spark","map","equivalent",".","Keeps","track","of","privacy_id","for","each","element",".","The","output","PrivateRDD","has","the","same","BudgetAccountant","as","this","one","."]
code: def map(self, fn: Callable) -> "PrivateRDD":
      """A Spark map equivalent.
  
      Keeps track of privacy_id for each element.
      The output PrivateRDD has the same BudgetAccountant as this one.
      """
      # Assumes that `self._rdd` consists of tuples `(privacy_id, element)`
      # and transforms each `element` according to the supplied function `fn`.
      rdd = self._rdd.mapValues(fn)
      return make_private(rdd, self._budget_accountant, None)
  
file_path: pipelinedp/pipeline_dp/private_spark.py
imports: from pyspark import RDD
  from typing import Callable, Optional
  import pipeline_dp
  from pipeline_dp import aggregate_params, budget_accounting
label_desc: Use image node_id 2 for calling the PrivateRDD obj's underlying member method code with example usage: obj.map(fn) and returns: make_private