Reply to post: Re: The Right Tool for a Lot of Jobs

Everyone loves programming in Python! You disagree? But it's the fastest growing, says Stack Overflow

bombastic bob Silver badge
WTF?

Re: The Right Tool for a Lot of Jobs

"Python is growing fast mainly because it is heavily used in a lot of fast growing fields, including web applications, high performance computing, analysing big data sets, machine learning, system management, etc., etc "

not sure I like where this is going. And not because Python is a BAD language [it is, in fact, a GOOD language]. Python is just NOT SUITED for anything "high performance".

When you use some of those libraries, they're coded VERY inefficiently. There was one specific example I ran into, either in matplotlib or numpy. It was GROSSLY inefficient the way it was implemented. I basically re-wrote code to avoid using it as much as possible, and made a significant speedup just from that. I can't remember what it was (sorry) but I remember doing this. I shaved 15 or 20 seconds off of a file upload operation JUST doing that. Then I shaved OVER A MINUTE off by using the external C program. What WAS taking 2 minutes (or more) is now taking around 10 seconds [because I didn't want to re-write ALL of the python code in C, but if I had, it would probably take less than 2 seconds].

Now, for generating charts, other than matplotlib's hideous API, it's "convenient". Sort of. OK maybe not, and I might have to go to using something else like Cairo but still...

In any case, watch your CPU utilization. If you write Python code and are charged by cloud services for CPU utilization, you'll save a LOT of cash by going wiht a C language utility instead, at least for the parts that do the number crunching, "high performance", etc..

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon