Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×
Programming Science

MIT's Newest fMRI Study: 'This is Your Brain on Code' (mit.edu) 9

Remember when MIT researchers did fMRI brain scans measuring the blood flow through brains to determine which parts were engaged when programmers evaluated code? MIT now says that a new paper (by many of the same authors) delves even deeper: Whereas the previous study looked at 20 to 30 people to determine which brain systems, on average, are relied upon to comprehend code, the new research looks at the brain activity of individual programmers as they process specific elements of a computer program. Suppose, for instance, that there's a one-line piece of code that involves word manipulation and a separate piece of code that entails a mathematical operation. "Can I go from the activity we see in the brains, the actual brain signals, to try to reverse-engineer and figure out what, specifically, the programmer was looking at?" asks Shashank Srikant, a PhD student in MIT's Computer Science and Artificial Intelligence Laboratory (CSAIL). "This would reveal what information pertaining to programs is uniquely encoded in our brains." To neuroscientists, he notes, a physical property is considered "encoded" if they can infer that property by looking at someone's brain signals.

Take, for instance, a loop — an instruction within a program to repeat a specific operation until the desired result is achieved — or a branch, a different type of programming instruction than can cause the computer to switch from one operation to another. Based on the patterns of brain activity that were observed, the group could tell whether someone was evaluating a piece of code involving a loop or a branch. The researchers could also tell whether the code related to words or mathematical symbols, and whether someone was reading actual code or merely a written description of that code.....

The team carried out a second set of experiments, which incorporated machine learning models called neural networks that were specifically trained on computer programs. These models have been successful, in recent years, in helping programmers complete pieces of code. What the group wanted to find out was whether the brain signals seen in their study when participants were examining pieces of code resembled the patterns of activation observed when neural networks analyzed the same piece of code. And the answer they arrived at was a qualified yes. "If you put a piece of code into the neural network, it produces a list of numbers that tells you, in some way, what the program is all about," Srikant says. Brain scans of people studying computer programs similarly produce a list of numbers. When a program is dominated by branching, for example, "you see a distinct pattern of brain activity," he adds, "and you see a similar pattern when the machine learning model tries to understand that same snippet."

But where will it all lead? They don't yet know what these recently-gleaned insights can tell us about how people carry out more elaborate plans in the real world.... Creating models of code composition, says O'Reilly, a principal research scientist at CSAIL, "is beyond our grasp at the moment." Lipkin, a BCS PhD student, considers this the next logical step — figuring out how to "combine simple operations to build complex programs and use those strategies to effectively address general reasoning tasks." He further believes that some of the progress toward that goal achieved by the team so far owes to its interdisciplinary makeup. "We were able to draw from individual experiences with program analysis and neural signal processing, as well as combined work on machine learning and natural language processing," Lipkin says. "These types of collaborations are becoming increasingly common as neuro- and computer scientists join forces on the quest towards understanding and building general intelligence."
This discussion has been archived. No new comments can be posted.

MIT's Newest fMRI Study: 'This is Your Brain on Code'

Comments Filter:
  • did they test if they where on pot or not as well?

  • This is a largely bullshit study -- poorly designed, p-hacked all to hell, with an absolutely tiny R. You can safely ignore everything in the actual study, let alone in the over-hyped popular press story copy-pasted from a press release written by an English major in the university's PR department who only understood some of the words in the paper and none of the science.
  • A metastudy. (Score:4, Interesting)

    by Gravis Zero ( 934156 ) on Saturday December 31, 2022 @05:35PM (#63171036)

    This actually a study of the results of other studies. What they did is take the data of the other studies and then push it through various machine learning models to see if they could categorize the particular thing (sentence v. code, variable language, data type, and control flow) that the programmer was looking at and thinking about. They also looked at classifying static analysis versus dynamic analysis. The results aren't super impressive as accuracy tops out at 60% but it's merely a metastudy.

  • It's a fascinating and probably useful tool, but I'm wary of the people insisting it'll cure backaches, scrub your pots clean, and keep your breath smelling fresh.
    After all, I recall the breathless reports about its potential at the same time some wag had it detecting brain activity in, Iirc, salmon filets.

  • Please put on this helmet while whiteboarding the entire solution to our main business problem with a room full of people heckling you.

It's a naive, domestic operating system without any breeding, but I think you'll be amused by its presumption.

Working...