Guard matplotlib import. Also use agg backend so we don't need to link TK with matplotlib.
Guard matplotlib import. Also use agg backend so we don't need to link TK with matplotlib.

PiperOrigin-RevId: 210438548

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