And to Java. That's more of a surprise. Most of the gains may have come from architecture changes though: "The combined effect of better architecture and Elixir saved Pinterest over $2 million per year in server costs".
Python is fine to build a first version; you should never pick a language or architecture because you THINK you may need its performance, that's cargo cult. Pinterest could not have predicted they needed 200 servers for this workload - and they probably didn't for a long time.