<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _process_sum_prod(self, func, **kwargs):
 """Calculates the sum or product of the DataFrame. Args: func: Pandas func to apply to DataFrame. ignore_axis: Whether to ignore axis when raising TypeError Return: A new QueryCompiler object with sum or prod of the object. """

        axis = kwargs.get("axis", 0)
        min_count = kwargs.get("min_count", 0)

        def sum_prod_builder(df, **kwargs):
            return func(df, **kwargs)

        if min_count <= 1:
            return self._full_reduce(axis, sum_prod_builder)
        else:
            return self._full_axis_reduce(axis, sum_prod_builder)