The overriding image is created by the simile: this is a comparison using 'like' or 'as'. The comparison highlights the tired muscular straining of the animal as an association with the described object.
The phrase also includes gentle aural techniques. Sibilance (a form of alliteration using the ‘s’ sound.) is commonly used to allude to the hissing sound of a snake, and is often part of imagery involving this animal. Alliteration of the ‘k’ sound (like/snake) is also used: this is another harsh sound. There is a contrast in the idea in that the harshness of the sounds associated with the snake do not sit with the adjective ‘weary’. A tired snake would not seem so stretched out, one would have thought.
Of course if the snake were ‘wary’, it would be in a state of anxiety and tension, which may reflect the idea of stretching more credibly.