| >shifting all the runtime heavy computation to C-implementations... this article is missing the whole point The author understands your perspective but he's deliberately using a different one. The idea is that a data scientist user would realistically use NumPy/SciPy optimized C libraries instead of writing raw loops in "pure Python" to walk pure Python lists that model matrices. Therefore comparing pure Python code (interpreted by the canonical CPython interpreter) to Julia is the opposite of his goal. The article's title is: "How To Make Python Run As Fast As Julia" The author wanted to write about: "How To Make Python _Projects_ Run As Fast As Julia" But many readers insist that the article should have been: "How To Make Pure Python Code Run As Fast As Julia" (The 2nd type of article is also interesting, but the author didn't write it and didn't claim to.) The article's comment permalink doesn't seem to jump to his exact comment so I'll copypaste the text here: >There is indeed a disagreement about the purposes of the benchmarks. I see at least two purposes at stake here. >1. A user point of view, which is to see how t best accomplish things in a given language. It is the result of various tradeoffs, including this: balance the time and effort to code something with the efficiency you get. That's the view of most Python users reacting to my post. We don't mind using Python libraries, even if they aren't written in 'pure' Python. Actually, the massive set of existing Python libraries is probably one key reason for its success. >2. A language implementer point of view, which focuses on how elementary language operations perform. That's the purpose of Julia micro benchmarks I think. >If people do not agree on the yardstick they use, then the discussion is not going to be fruitful. This disagreement explains most of the comments I saw until now. >I am using the 'user point of view' in my post |
In this case the way the author shows it isn't the best one: he modifies Python code to be more realistic - that's ok, but doesn't he do the same thing for Julia? Obviously, writing a recursive fibonacci functions isn't the best way to implement it. Obviously, using caching can improve performance. But why not to apply these changes to both implementations?