parameters: (chain, map_func, reduce_func, init=MISSING_PARAM, start=None, end=None, cpu_count=psutil.cpu_count())
return_statement: return mapreduce_block_ranges(
          chain,
          map_range_func,
          reduce_func,
          init,
          start,
          end,
          cpu_count
      )
docstring: Initialized multithreaded map reduce function over a stream of transactions
docstring_summary: Initialized multithreaded map reduce function over a stream of transactions
docstring_tokens: Initialized multithreaded map reduce function over a stream of transactions
function: def mapreduce_txes(chain, map_func, reduce_func, init=MISSING_PARAM, start=None, end=None, cpu_count=psutil.cpu_count()):
      """Initialized multithreaded map reduce function over a stream of transactions
      """
      def map_range_func(blocks):
          if isinstance(init, type(MISSING_PARAM)):
              return reduce(
                  reduce_func,
                  (map_func(tx) for block in blocks for tx in block)
              )
          else:
              return reduce(
                  reduce_func,
                  (map_func(tx) for block in blocks for tx in block),
                  copy.deepcopy(init)
              )
      return mapreduce_block_ranges(
          chain,
          map_range_func,
          reduce_func,
          init,
          start,
          end,
          cpu_count
      )
function_tokens: def mapreduce_txes ( chain , map_func , reduce_func , init = MISSING_PARAM , start = None , end = None , cpu_count = psutil . cpu_count ( ) ) : def map_range_func ( blocks ) : if isinstance ( init , type ( MISSING_PARAM ) ) : return reduce ( reduce_func , ( map_func ( tx ) for block in blocks for tx in block ) ) else : return reduce ( reduce_func , ( map_func ( tx ) for block in blocks for tx in block ) , copy . deepcopy ( init ) ) return mapreduce_block_ranges ( chain , map_range_func , reduce_func , init , start , end , cpu_count )