[ONNX] Fix reduce node shape inference (#85765)
Fix logic in `ProcessReduceNode`. Previously a scalar was assigned for output shape of reduce nodes
when `axes` attribute was not provided, regardless of the value of `keepdims_i` attribute. Hence it is
incorrectly assuming all output axes should be folded.
Since input rank is known, this fix populates axes to be `[0, 1, ..., input_rank - 1]` if axes is not
provided.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/85765
Approved by: https://github.com/abock