跳到正文
r/MachineLearning· /u/Sad_Measurement_7502·· 3 小时前AI 评分41

MIT 研究员用纯 Python 为爱犬 Jackie 打造数字孪生大脑

I turned my dog Jackies Brain into a working AI [P]

AI 导读

MIT 研究员基于爱犬 Jackie 的 6 次 fMRI 与 EEG 同步记录(含心率、呼吸、加速度及嗅觉球、杏仁核、伏隔核 BOLD 值),用纯 Python 构建了一个数字孪生大脑,未使用 PyTorch 或 TensorFlow。

正文
I turned my dog Jackies Brain into a working AI [P]

Hey everyone,I’m a researcher at MIT and this whole thing started completely by accident. My dog Jackie had to do a couple of veterinary MRI scans last year for a minor issue that luckily turned out fine. While she was already in the scanner the vet team (who are honestly the coolest people) let me stay and we ended up running a few extra short functional sequences just out of curiosity. Later we also did some wireless EEG at home with a custom soft cap while she was exposed to different smells, other dogs, walks, food, etc.I somehow ended up with six clean sessions (J001–J006) that have:

  • simultaneous T2*-weighted EPI fMRI
  • EEG band power (theta, alpha, beta, gamma)
  • heart rate, respiration, acceleration
  • simple behavioural notes (licking, etc.)
  • BOLD values extracted from olfactory bulbs left/right, amygdala left/right and nucleus accumbens left/right

Plus three really nice axial slices under different social conditions:

  1. random street dog (novel, HR went up to 124 bpm, clear bilateral amygdala activation)
  2. her actual best friend dog (HR 112, more balanced midbrain/temporal response)
  3. the neighbor dog after several exposures (HR down to 98, strong bilateral temporal activation)

I got a bit obsessed and decided to turn all of that into a digital twin. Not a fancy deep learning model, just pure Python. No PyTorch, no TensorFlow, nothing. Only dataclasses, deques, some basic statistics and a state machine.The system keeps:

  • a 6-dimensional emotional vector (joy, curiosity, calm, excitement, anxiety, affection)
  • a 25-region activation map based on a simplified canine atlas
  • current physiological state (HR, arousal index, etc.)

When you type a stimulus the pipeline does roughly this:

  1. StimulusMapper tries to match it against the real sessions (or does simple fuzzy matching for the social ones)
  2. Emotion deltas that were derived by averaging the real BOLD + EEG values get applied
  3. Regions decay toward baseline and then get BOLD injected from the matched session
  4. Special social boosts are added for the three dog conditions
  5. Heart rate is updated to the value we actually measured
  6. Everything is stored in a memory buffer

https://github.com/StoopwenpueNq/jackie-fmri-sim/tree/main

I’m fully aware this is a heavily simplified linear approximation. It doesn’t do proper HRF convolution or biophysical neural mass modelling. I deliberately kept it transparent so every number can be traced back to the actual measurements we took from Jackie. The goal was more “does this feel alive and inspectable” than “state of the art accuracy”.Still, when you feed it “best friend dog” vs “random street dog” the emotional state and the dominant regions shift in ways that actually match what we saw in the scanner and in real life. That part still gives me chills every time.Would really appreciate feedback from anyone who works with animal fMRI, canine cognition, affective computing, or just likes weird personal science projects. Happy to share more details about the ROI extraction, the soft EEG cap we used, the regression weights, whatever.Also if anyone has suggestions on how to make the region dynamics a bit more realistic without adding huge dependencies I’m all ears.Anyway… Jackie is currently asleep on the couch after a long walk. She has no idea she now has a digital twin that gets anxious about street dogs and super happy about her best friend.Thanks for reading this far.
Happy to answer any questions.

https://preview.redd.it/mc1agct2wevh1.png?width=1130&format=png&auto=webp&s=233c874a850516ca31b70057ed38083701840c7b

https://preview.redd.it/ph9vvlz1wevh1.png?width=1151&format=png&auto=webp&s=d54aa4e78bfcad37ae9cb9676030bc616b52e201

https://preview.redd.it/ie2shgv0wevh1.png?width=1164&format=png&auto=webp&s=28cba4b3cfd50d4bb6c0cd4ab02e3a801b15ef03

https://preview.redd.it/oum4momsvevh1.png?width=622&format=png&auto=webp&s=f3695972fa6260a17821b334010f15beda068914

submitted by /u/Sad_Measurement_7502
[link] [留言]

来源:r/MachineLearning · reddit.com