pyspark.SparkContext.accumulator¶
-
SparkContext.accumulator(value, accum_param=None)[source]¶ Create an
Accumulatorwith the given initial value, using a givenAccumulatorParamhelper object to define how to add values of the data type if provided. Default AccumulatorParams are used for integers and floating-point numbers if you do not provide one. For other types, a custom AccumulatorParam can be used.