More guards against hparams that may not exist.
More guards against hparams that may not exist.

PiperOrigin-RevId: 229806871

tensorflow/tensor2tensor,tensorflow/tensor2tensor,tensorflow/tensor2tensor,tensorflow/tensor2tensor,tensorflow/tensor2tensor