def map_generic(self, func):
def process_record(val):<EOL><INDENT>newval = empty(<NUM_LIT:1>, dtype="<STR_LIT:object>")<EOL>newval[<NUM_LIT:0>]  = func(val)<EOL>return newval<EOL><DEDENT>rdd = self._rdd.mapValues(process_record)<EOL>nchunks = self.getnumber(self.plan, self.vshape)<EOL>newshape = tuple([int(s) for s in r_[self.kshape, nchunks]])<EOL>newsplit = len(self.shape)<EOL>return BoltArraySpark(rdd, shape=newshape, split=newsplit, ordered=self._ordered, dtype="<STR_LIT:object>")<EOL>
Apply a generic array -> object to each subarray

The resulting object is a BoltArraySpark of dtype object where the
blocked dimensions are replaced with indices indication block ID.