work around precision error in constraint solver (#101607)
In https://github.com/pytorch/pytorch/pull/101307 we tried to fix https://github.com/pytorch/pytorch/issues/101093 using `nsimplify` to convert floats into rationals, but the fix is not reliable: it is possible for `nsimplify` to pick constants that don't work.
Currently, constraint solving is only used by `export`, but constraints are added in all modes. This means that we can hit this issue even in non-`export` modes. This diff works around this issue for such modes by delaying raising such failures until constraint solving.
Differential Revision: [D45922797](https://our.internmc.facebook.com/intern/diff/D45922797/)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/101607
Approved by: https://github.com/ezyang