'Piecewise function printer'

def _print_Piecewise(self, expr):

    exprs = '[{0}]'.format(','.join((self._print(arg.expr) for arg in expr.args)))
    conds = '[{0}]'.format(','.join((self._print(arg.cond) for arg in expr.args)))
    return '{0}({1},    {2},    default=numpy.nan)'.format(self._module_format('numpy.select'), conds, exprs)
