maedoc/autotvb/boilerplate
- community
Checking that the SKILL.md file is still in the repository.
Essential TVB simulation boilerplate and core building blocks. Use when starting any TVB workflow, importing libraries, configuring connectivity, models, coupling, monitors, and the simulator. Triggers on `tvb.simulator.lab`, `connectivity.Connectivity`, `simulator.Simulator`, `configure()`.
Install
npx vskill@latest install maedoc/autotvb/boilerplateSKILL.md
TVB Driver: Boilerplate & Core Simulation
Essential Imports
Forward Monitors (EEG, MEG, iEEG)
Forward solution monitors require sensor objects loaded from TVB data files. Always import and configure sensors before the monitor.
Critical: forward monitors must have their configure() called before they are passed to Simulator(). The simulator's own configure() does not auto-configure monitor internals.
Building a Simulation
Every TVB simulation follows this pattern:
Critical Rules
- Always `configure()` connectivity before running.
- Forward monitors (
EEG,MEG,iEEG) must have their ownconfigure()called before being passed toSimulator(). - Array wrapping: Parameters must be numpy arrays, even scalars:
numpy.array([value]). - Region numbering: Default connectivity has 76 regions. V1/V2 are usually regions 35, 36.
- Prose/code drift: If markdown says "amp = 1e-3", the code must literally set
ampto1e-3. - Conduction speed belongs on
Connectivity, NOTSimulator():conn.speed = numpy.array([4.0]); conn.configure(). - simulation_length belongs on
sim(...)orsim.run(...), NOT in theSimulator()constructor.
Common API Mistakes to Avoid
| Wrong | Why | Right | |
|---|---|---|---|
monitors.EEG(period=5.0) without sensors | Missing required sensors attr → configure() raises TraitAttributeError | monitors.EEG(sensors=sensors_eeg, projection=proj_eeg, period=5.0); mon_eeg.configure() | |
monitors.SEEG(...) | Class removed in TVB 2.x; use monitors.iEEG | monitors.iEEG(sensors=sensors_ieeg, ...) | |
conduction_speed=4.0 in Simulator(...) | Must be set on Connectivity | conn.speed = numpy.array([4.0]); conn.configure() | |
simulation_length=1e3 in Simulator(...) | Must be in sim(...) or sim.run(...) | sim.run(simulation_length=1e3) | |
numpy.concatenate([a[0] for a in data]) on scalar times | concatenate fails for 0-d scalars | numpy.array([a[0] for a in data]) | |
for (t1, y1), (t2, y2) in sim(...) when periods differ | A monitor may yield None, cannot unpack | Use None-safe check per index |
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills-in-progress/driver/boilerplate/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/maedoc/autotvb/boilerplate)