In my experience, scientists are like extremely junior developers with PhDs. They name functions "wstok" instead of "whitespace_tokenizer" because it uses fewer keystrokes. They can't be bothered to commit code. And when you do manage to get them to commit code, it is isn't the same code. It is close to the same code, but different. They think "close enough" is close enough, even though they recognize that without th…
This is accurate. I am a good example of this phenomenon. Scientists don't know how to code in a way that is intelligible to someone else, and in academic shops, there's probably only going to be one person who writes/understands a program in the first place. This one person probably views coding purely as an icky means to an end, and his adviser thinks it's a waste of time if it even reaches his knowledge whatsoever…
Too much of the research process is now shrouded by the opaque use of computers
21–30 of 55 posts
Re: Too much of the research process is now shrouded by the opaque use of computers
#22Earlier quoted context omitted.
This is accurate. I am a good example of this phenomenon. Scientists don't know how to code in a way that is intelligible to someone else, and in academic shops, there's probably only going to be one person who writes/understands a program in the first place. This one person probably views coding purely as an icky means to an end, and his adviser thinks it's a waste of time if it even reaches his knowledge whatsoever…
I think the core of the problem is that coding and documentation are not considered part of the "science". Contrast it with writing papers, which is understood as communication with scientific peers, the community, and therefore is "science" -- and, of course, is one of the measures of scientific progress. Writing code is not. Anecdotally, writing papers about code is (on occasion), so maybe there is a way to convinc…
Or maybe they write hash, I don't know. But their approach isn't 'let me craft some good code', its 'let me describe my thesis' which will end up in a different place than any trained software professional.
Re: Too much of the research process is now shrouded by the opaque use of computers
#23In my experience, scientists are like extremely junior developers with PhDs. They name functions "wstok" instead of "whitespace_tokenizer" because it uses fewer keystrokes. They can't be bothered to commit code. And when you do manage to get them to commit code, it is isn't the same code. It is close to the same code, but different. They think "close enough" is close enough, even though they recognize that without th…
Ive seen some bad stuff, including thousand line methods and production software whose source code is nowhere to be found. But the biggest forehead slap that I think I've encountered is when working on an automated trading system. I had just started working on the system when the original trader who had developed the algo quit. I saw him after work at a bar a couple weeks later and made some comment about how difficult it was to work on that codebase. He said that he made some of the trading logic purposefully difficult to understand so that it would be difficult for someone to read the code, get a job elsewhere, and replicate his work for a different company. Thats an insane way to write software. It assumes that all of the value is in the idea itself (and this algo was hardly rocket science by the way) rather than in a functional piece of software that is easy to modify and debug.
Re: Too much of the research process is now shrouded by the opaque use of computers
#24In my experience, scientists are like extremely junior developers with PhDs. They name functions "wstok" instead of "whitespace_tokenizer" because it uses fewer keystrokes. They can't be bothered to commit code. And when you do manage to get them to commit code, it is isn't the same code. It is close to the same code, but different. They think "close enough" is close enough, even though they recognize that without th…
I think that's a bit unfair to label all scientists like that. There are many of us that care about writing good code and working in version control. You just need to browse github to see many such people. There's not much incentive to actually do this in an academic environment, however, other than improving their own ability to improve and maintain their own codes. A well documented code available for everyone is u…
Yes, I'm also aware that I made a general statement about generalities, though I think this one is a mostly correct generality.
Re: Too much of the research process is now shrouded by the opaque use of computers
#25Re: Too much of the research process is now shrouded by the opaque use of computers
#26 Ax_1 += Bx_1 + Cx_1 # Add Bx_1 to Cx_1
Ax_2 += Bx_2 + Cx_2 # Same thing, but for Ax_2
Ax_3 += Bx_3 + Cx_3 # "
Ay_1 += By_1 + Cy_1 # "
...
Code with comparable functionality is copied and pasted instead of being factored into a single function. Everything is tightly-coupled: changing one line of code is like pulling the keystone out of a bridge designed by an oyster chef. If there are any functions, then calling one mutates at least 7 global variables and induces 13 side effects that are more unpredictable than eigenstate selection. File formats are non-standard and consist largely of one giant concatenation of every variable in the program (all converted to strings of course).Not-invented-here-syndrome is a badge of honor (LAPACK? Bah! I'll write my own Gaussian elimination routine for this matrix with a million entries). Libraries are embraced with the exuberance of a picky eater encountering durian (as a rule of thumb, anything that is open source and has been vetted by thousands of users is probably untrustworthy).
It is considered a waste of time to learn basic CS algorithms — efficiency is merely an implementation detail, so problems that could have been solved with a clever algorithm and an iPhone are instead brute-forced using millions of hours of supercomputer time. Complexity classes are the abstract nonsense of computer science — it's much easier to throw more hours at the problem (so what if it's NP-hard? My algorithm probably converges to the global minimum. Why wouldn't it?)
When garbage-collected languages are used, programs spend 99% of their time allocating and deallocating small quantities of memory in tightly nested inner loops (16 of them, no less). "Inlining" means putting comments inside of the code instead of above it (if there even are any comments). "Cache locality" has something to do with GPS systems. "Hashing", "recursion", and "quicksort" are the names of recently-announced smartphones. And doesn't "SIMD" stand for the Society for Inherited Metabolic Disorders?
/rant
It's a mess. Granted, there are researchers who write very high quality code, but they are few and far between. I think the main problem is that a lot of students/professors who get involved in computational research never had a good CS background. Perhaps they had one "Computing for Engineers" class that taught Matlab or Python, but that isn't nearly sufficient for research-quality code. While I had the advantage of taking up programming as a hobby during childhood, most graduate students have never programmed before in their life. They're expected to learn something like C++ in a week (that's not a hypothetical example).
Many researchers are afraid to publish their code alongside their paper because they know the code is low-quality. And that awareness causes a lot of insecurities. If someone finds a bug in their 2-3 year research project, then their entire conclusion might be invalidated. But I don't think that's the biggest worry (most scientists ultimately want to know the truth about their subject of study). I think the biggest fear is of losing prestige, losing a chance for tenure, or having funding revoked.
To fix this problem, there is a crucial and urgent need for the academic community to reduce the penalty associated with making honest mistakes.
Mistakes are simply part of the research process. Humans are fallible — everyone is going to mess up at some point. And instead of propagating this academic "chilling effect", it would be much better for the whole scientific community if everyone quit worrying about messing up and instead published their code in a highly visible location, subjecting it to the highly critical (yet extremely beneficial) scrutiny that it deserves.
Re: Too much of the research process is now shrouded by the opaque use of computers
#27The solution is obvious - provide a github repository with all the code for the research. Provide clear ways to reproduce all the results of the research from raw data by running build. Bonus points: Hirschware as software license.
Re: Too much of the research process is now shrouded by the opaque use of computers
#28[1] http://depsy.org/ and the blog post announcing it: http://blog.impactstory.org/introducing-depsy/
Re: Too much of the research process is now shrouded by the opaque use of computers
#29That should leave some scars that can be built on in the phd. program.
(And either make sure they have a full number tower (probably best for "most"), or make sure they know that computers, despite their name, suffer from fundamental dyscalculia -- the ability to manipulate decimal numbers).
Re: Too much of the research process is now shrouded by the opaque use of computers
#30Earlier quoted context omitted.
But if somebody would read the publication in, say, 20 years, then the whole platform on which the computation has to run might have become obsolete. Suddenly, you have to look for emulators. Or even for emulators running emulators.
With some effort you could make it work, perhaps make a pull request. Programming languages will likely still be around. Using open formats and tools would likely help.
And this is even an example of a combination which once was considered mainstream.