Extend HasShape() to support partial shape assertion.
Extend HasShape() to support partial shape assertion.

PiperOrigin-RevId: 249263475

tensorflow/lingvo,tensorflow/lingvo,tensorflow/lingvo,tensorflow/lingvo