Maybe it is a bit more explicit to check `sign(y).rewrite(Piecewise) == sign(y)`?