Python was written with people like scientists in mind. Professionals write fast C libraries and then people who know just enough to get by use python to glue it all together.
Having just taught a bunch of scientists Python, I'm skeptical of this.
Stuff that is obvious to me, but really hard to explain to coding beginners:
* why `len(list)` but `str.join(...)`? I.e. why are there two ways to call functions?
* why does `[]` do so many different things? List comprehensions, list construction, subsetting, sometimes it secretly calls a method....
* why in the name of god is the first row called 0?
* and then why does [0:3] mean rows 1, 2 and 3, not rows 0, 1, 2, 3 or 1, 2, 3, 4?
* ... except in pandas where sometimes [foo:bar] includes bar...
* in general, why is pandas so damn complex?
I thought it'd be easier to teach than R, but I'm not quite so certain now.
- plenty of scientists write good code; I think the "scientist can't code" meme is harmful.
- most of the people that write PyTorch code aren't necessarily scientists - they're software developers (data scientists, ML engineers, research engineers, whatever title - but their main job is to write code)
> Python was written with people like scientists in mind.
Python had nothing to do with scientists when it started. It was written to be readable and easy to use and it started as a hobby project. It existed for over 15 years until the data science / ML ecosystem started growing around it.