Converting Transformers to Polynomial Form for Secure Inference Over Homomorphic Encryption