diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..300867b9 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,6 @@ +# databook/glossary.md is rendered from the Allen Glossary by +# scripts/build-glossary-page.mjs and committed because the databook is built +# from Markdown by a capsule that has no Node. Marking it generated collapses it +# in pull request diffs, so a reviewer reads the generator rather than several +# thousand lines of its output. +databook/glossary.md linguist-generated=true diff --git a/.github/workflows/publish-glossary.yml b/.github/workflows/publish-glossary.yml new file mode 100644 index 00000000..21050bdc --- /dev/null +++ b/.github/workflows/publish-glossary.yml @@ -0,0 +1,161 @@ +name: Publish glossary page + +# Publishes just databook/glossary.md to the live site, without Code Ocean. +# +# The rest of the databook is built in the Code Ocean capsule, because its pages +# execute notebooks against attached data assets. The glossary page executes +# nothing, so it can be built by Actions alone and dropped onto gh-pages as a +# single file. The other ~120 pages keep whatever the last capsule run deployed. +# +# That means the glossary can be published ahead of a full rebuild and may sit +# slightly out of step with the rest of the site — which is the accepted +# trade-off for not needing a capsule run to ship a definition fix. +# +# Why a full `jb build` and not something cheaper: the page has to carry the +# theme's chrome (header, sidebar nav, breadcrumbs) to look like part of the +# book, and only Sphinx can produce that. Execution is switched off, so the +# build is quick and the notebook cache is never touched. glossary.html comes +# out byte-identical to what the capsule would produce, provided the toolchain +# matches — see the asset check below, which is what enforces that. + +on: + push: + branches: [main] + paths: + - databook/glossary.md + - databook/_toc.yml + - databook/_config.yml + - scripts/build-glossary-page.mjs + - .github/workflows/publish-glossary.yml + workflow_dispatch: {} + +permissions: + contents: write + +concurrency: + group: publish-glossary + cancel-in-progress: false # never interrupt a push to gh-pages + +jobs: + publish: + runs-on: ubuntu-latest + steps: + - name: Checkout main + uses: actions/checkout@v4 + with: + path: src + + - name: Checkout gh-pages + uses: actions/checkout@v4 + with: + ref: gh-pages + path: site + + - uses: actions/setup-python@v5 + with: + python-version: "3.11" + + # Must match the version the Code Ocean capsule builds the rest of the + # book with — it is pinned there too, in the capsule's environment file in + # the databook-build repository. This page links to the _static bundle + # already on gh-pages rather than shipping its own, so a mismatch still + # builds but renders against the wrong stylesheet: the theme's header + # dropdowns collapse into bare bullet lists. + # + # If the capsule is ever upgraded, change it there first, let a full + # capsule build deploy, then change it here. To check the two agree, the + # theme digests must be equal: + # + # curl -s https://allenswdb.github.io/background/background.html \ + # | grep -o 'pydata-sphinx-theme.css?digest=[a-f0-9]*' + # + # 0.15.1 gives dfe6caa3a7d634c4db9b, matching the deployed site, and needs + # no assets the live site lacks. + - name: Install Jupyter Book + run: pip install "jupyter-book==0.15.1" + + - name: Build the book with execution off + working-directory: src + run: | + python - <<'PY' + import re + p = "databook/_config.yml" + s = open(p).read() + # the capsule's cache path does not exist here, and nothing on the + # glossary page needs a kernel + s = re.sub(r"execute:\n(?: .*\n)+", "execute:\n execute_notebooks: 'off'\n", s) + open(p, "w").write(s) + PY + jb build -n --keep-going databook + + # gh-pages is force-pushed wholesale by the capsule's `ghp-import -f`, so + # it can move under us at any moment. Everything below is therefore done + # against a freshly fetched gh-pages and retried on rejection, rather than + # against the checkout taken at the start of the job. + # + # Losing a race is harmless: the capsule builds from main, and main's + # glossary.md is kept current by sync-glossary.yml, so a capsule deploy + # that lands on top of us carries the same page anyway. + - name: Publish onto gh-pages + working-directory: site + run: | + build=../src/databook/_build/html + test -f "$build/glossary.html" || { echo "::error::glossary.html was not built"; exit 1; } + + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + + # every _static path the page links to, digests stripped + grep -oE '_static/[^"?'"'"' ]+' "$build/glossary.html" | sed 's/?.*//' | sort -u > /tmp/need.txt + + for attempt in 1 2 3; do + git fetch origin gh-pages + git reset --hard origin/gh-pages + + missing=0 + : > /tmp/add.txt + while read -r f; do + [ -f "$f" ] && continue + # a filename the live site has never seen: safe to add, because + # nothing already deployed links to it + if [ -f "$build/$f" ]; then + echo "$f" >> /tmp/add.txt + else + echo "::error::page needs $f but the build did not produce it" + missing=1 + fi + done < /tmp/need.txt + [ "$missing" = "1" ] && exit 1 + + if [ -s /tmp/add.txt ]; then + echo "::warning::Toolchain here differs from the one that built the live site;" + echo "::warning::adding $(wc -l < /tmp/add.txt) new asset(s). Shared assets are left alone, so this" + echo "::warning::page may drift visually until the capsule and this workflow are pinned alike." + cat /tmp/add.txt + fi + + cp "$build/glossary.html" glossary.html + mkdir -p _sources + cp "$build/_sources/glossary.md.txt" _sources/ 2>/dev/null || true + # additive only: never overwrite an asset the other pages depend on + while read -r f; do + mkdir -p "$(dirname "$f")" + cp "$build/$f" "$f" + done < /tmp/add.txt + + if [ -z "$(git status --porcelain)" ]; then + echo "Nothing changed; the published page is already current." + exit 0 + fi + + git add -A + git commit -m "Publish glossary page from ${GITHUB_SHA::7}" + if git push origin gh-pages; then + echo "Published on attempt $attempt." + exit 0 + fi + echo "::notice::gh-pages moved under us; refetching and retrying." + done + + echo "::error::could not publish after 3 attempts" + exit 1 diff --git a/.github/workflows/sync-glossary.yml b/.github/workflows/sync-glossary.yml new file mode 100644 index 00000000..0c3a0ab9 --- /dev/null +++ b/.github/workflows/sync-glossary.yml @@ -0,0 +1,132 @@ +name: Sync glossary + +# Regenerates databook/glossary.md from the Allen Glossary repository, which is +# the source of truth for the definitions. This repository only ever reads that +# one; the renderer (scripts/build-glossary-page.mjs) lives here, so the +# databook owns how it presents the data and the glossary stays a pure source. +# +# Why polling rather than being pushed to: the glossary is a personal repo +# outside this org, so a push-based hook would need a token minted here and +# stored there. Polling a public repo needs no secret anywhere, and a daily +# check is enough to keep the page from drifting. +# +# If someone later wants the page to update within seconds of a merge rather +# than within a day, add a workflow over in the glossary repo that fires a +# repository_dispatch with type `glossary-updated` at this repo. The trigger is +# already wired up below; it needs a fine-grained PAT with "contents: write" on +# this repository, stored as a secret there. Nothing here changes. +# +# This never pushes to main. It opens a PR, which is also where you preview the +# rendered page before it goes live in the next databook build. + +on: + # GitHub switches scheduled workflows off after 60 days without a commit, and + # this book is worked on in a burst once a year, so the schedule alone would + # be dormant for most of it. Syncing on push as well covers that: during the + # quiet months nothing needs syncing anyway, and the first push of the next + # season pulls the glossary current before anyone looks at it. The run is + # cheap and opens nothing when the glossary has not moved. + push: + branches: [main] + schedule: + - cron: "17 13 * * *" # ~06:17 Pacific, daily + workflow_dispatch: {} + repository_dispatch: + types: [glossary-updated] + +permissions: + contents: write + pull-requests: write + +concurrency: + group: sync-glossary + cancel-in-progress: true + +jobs: + sync: + runs-on: ubuntu-latest + steps: + - name: Checkout databook + uses: actions/checkout@v4 + with: + path: databook-repo + + # Defaults to the canonical glossary. A fork can point this at its own + # copy by setting a GLOSSARY_REPO repository variable, so the file stays + # correct as-is when a fork's branch is opened as a PR upstream. + - name: Checkout glossary source (read-only) + uses: actions/checkout@v4 + with: + repository: ${{ vars.GLOSSARY_REPO || 'AllenInstitute/allen-connectomics-glossary' }} + path: glossary-src + + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: 20 + + - name: Regenerate the glossary page + id: gen + run: | + sha="$(git -C glossary-src rev-parse HEAD)" + echo "sha=$sha" >> "$GITHUB_OUTPUT" + # Tee the generator's own report so the pull request can carry it. + # A stale alias does not stop the sync, it just quietly costs a + # cross-reference its link, so the report has to reach a reviewer. + node databook-repo/scripts/build-glossary-page.mjs \ + --source glossary-src \ + --repo "${{ vars.GLOSSARY_REPO || 'AllenInstitute/allen-connectomics-glossary' }}" \ + --out databook-repo/databook/glossary.md \ + --commit "$sha" 2>&1 | tee /tmp/gen.log + + { + echo 'report<> "$GITHUB_OUTPUT" + + # The generator is deterministic, so an unchanged glossary leaves the + # working tree clean and no PR is opened. + - name: Check for changes + id: diff + working-directory: databook-repo + run: | + if git diff --quiet -- databook/glossary.md; then + echo "changed=false" >> "$GITHUB_OUTPUT" + echo "Glossary is already up to date." + else + echo "changed=true" >> "$GITHUB_OUTPUT" + git diff --stat -- databook/glossary.md + fi + + - name: Open pull request + if: steps.diff.outputs.changed == 'true' + uses: peter-evans/create-pull-request@v6 + with: + path: databook-repo + branch: bot/sync-glossary + delete-branch: true + title: "Sync glossary from allen-connectomics-glossary@${{ steps.gen.outputs.sha }}" + commit-message: | + Regenerate databook/glossary.md from AllenInstitute/allen-connectomics-glossary@${{ steps.gen.outputs.sha }} + body: | + Regenerated `databook/glossary.md` from + `${{ vars.GLOSSARY_REPO || 'AllenInstitute/allen-connectomics-glossary' }}` + at commit `${{ steps.gen.outputs.sha }}`. + + This file is generated — review the change upstream rather than editing it here. + Note that this PR does not build the databook, so give the rendered page a look + before merging if the diff touches anything structural. + +
Alias map report + + ``` + ${{ steps.gen.outputs.report }} + ``` + + Stale entries are skipped rather than failing the sync, so anything flagged + here means a cross-reference has quietly lost its link. Fix in + `databook/glossary-aliases.json`. +
+ labels: automated,glossary diff --git a/databook/glossary-aliases.json b/databook/glossary-aliases.json new file mode 100644 index 00000000..196bcca4 --- /dev/null +++ b/databook/glossary-aliases.json @@ -0,0 +1,52 @@ +{ + "//": [ + "Extra names under which a glossary term can be cross-referenced.", + "", + "The databook writes {term}`basket cell`; the glossary calls that entry", + "'Basket cell (BC)'. Sphinx matches glossary terms by their exact text, so", + "without a mapping the reference resolves to nothing, renders as plain text,", + "and warns under `jb build -n`. Each key below is added as an additional term", + "line on the entry it names, so both spellings reach the same definition.", + "", + "Keys are what the databook writes. Values are glossary term ids, taken from", + "the `id` field in the glossary repo's data/terms.js. Ids are used rather", + "than display names so that rewording a term upstream does not silently", + "break the mapping — build-glossary-page.mjs fails loudly if an id here no", + "longer exists, or if an alias collides with a real term name.", + "", + "Delete an entry once the glossary defines that spelling itself.", + "", + "Matching is case-insensitive, so one casing per name is enough — but the", + "casing chosen here is what the anchor is named after. Pages already built", + "and deployed link to the anchors the previous glossary produced, so these", + "keys follow that capitalisation (Spike, not spike) to keep those links", + "working until the whole book is rebuilt." + ], + + "aliases": { + "Basket cell": "basket-cell", + "Bipolar cell": "bipolar-cell", + "CCF": "ccf", + "GECI": "geci", + "HVA": "higher-visual-area", + "ISI": "intrinsic-signal-imaging", + "LFP": "local-field-potential", + "Local field potential": "local-field-potential", + "Martinotti cell": "martinotti-cell", + "Minnie column": "column-microns", + "Parvalbumin-positive interneuron": "pv-neuron", + "Primary visual cortex": "visp-visal-visrl", + "retinotopic map": "retinotopy", + "ROI": "roi-mask", + "Somatostatin cell": "somatostatin-sst-cell", + "Spike": "action-potential", + "V1": "visp-visal-visrl", + "VISp": "visp-visal-visrl" + }, + + "unmapped": { + "//": "Referenced by the databook, absent from the glossary. Left unresolved on purpose rather than pointed at an approximate entry — the fix is to define them upstream, then delete them from here.", + "CSV": "A generic file format, not a glossary concept. Already unresolved before this page was generated.", + "GFP": "The nearest entry is [fluorophore], which defines the class of molecule rather than this particular one." + } +} diff --git a/databook/glossary.md b/databook/glossary.md index 8c953fcc..69a2726b 100644 --- a/databook/glossary.md +++ b/databook/glossary.md @@ -1,329 +1,3330 @@ + + # Glossary -:::{glossary} +249 terms across 19 categories, from the +[Allen Glossary](https://alleninstitute.github.io/allen-connectomics-glossary/). Search matches names, definitions, categories and dataset +names; the category legend doubles as a filter, so clicking one or more pills narrows the +list. Every term has a permalink you can paste into an email — click a term name to copy +the link to it. + +:::::{raw} html + + +
+ +
+ + 249 terms +
+ +
+
+ Category — the colour on a card's edge. Click to filter. +
+
+ Connectomics + + + + + + + + + + + +
+
+ Physiology + + + + + + + +
+
+ Both + +
+ +
+
+
+ Illustration — colour inside a drawing means anatomy, never category +
+ structure / volume + dendrite + axon + synapse +
+

The illustrations are generated rather than hand-drawn. They are being + checked by the people who know the data, but errors cannot be ruled out at this stage — + read them as sketches of the idea, and trust the definition over the picture. + 148 of 249 terms have one.

+
+
+ +
+
+
3D reconstruction pipelineEM tilesegmented3D mesh
+
SEGMENT
+

3D reconstruction

+

Turning EM imagery into 3D neuron objects (dense segmentation → meshes).

+
+
+
Action potential — Hodgkin-Huxley simulation0-65+40mVstimuluspeak +41 mVundershootgKgNamS/cm²0510msNa+ opens and closes; K+ follows and repolarises
+
CELLTYPE
+

Action potential

+

A characteristic signal in excitable cell membranes: a potential-difference waveform that propagates along the membrane. In neurons it indicates activation. The trace is a Hodgkin-Huxley simulation: a brief current pulse opens sodium channels, which depolarise the membrane and then inactivate, while potassium conductance rises more slowly and repolarises it past rest.

+
+
+
DATA
+

AIND metadata schema

+

Six JSON classes describing a newer data asset: data description, subject, procedures, rig or instrument, session or acquisition, and processing. Where you look up which virus was injected, or what a capsule actually ran.

+ +
+
+
DATA
+

AllenSDK

+

The Python package for the Brain Observatory physiology datasets, wrapping downloads and metadata behind a cache object. Being retired in favour of reading NWB files directly, so new work should not start here.

+ +
+
+
amplitude_cutoff: spikes lost below the detection thresholddetection thresholdmissed spikesspike amplitudecount
+
QUALITY
+

amplitude_cutoff

+

Estimated fraction of the unit's spikes that fell below the detection threshold and were never recorded — a false-negative rate. Default threshold 0.1.

+ +
+
+
+Annotation + + + + + + +tagged point + + + + + + +id pt_position +7 (x,y,z) +8 (x,y,z) +table row +
+
TABLES
+

Annotation

+

Labeled data (points/tables) bound to locations or cells in the volume.

+
+
+
STIMULUS
+

Baiting / coupled vs uncoupled

+

Baiting: a reward an unchosen side would have given is held and delivered on the next choice of that side. Coupled or uncoupled describes whether the two sides' probabilities change together or independently.

+
+
+
Basket cell + + + + + + + + + + +
+
CELLTYPE
+

Basket cell (BC)

+

Inhibitory neuron whose synaptic output targets the cell body and proximal dendrites of excitatory neurons. Many basket cells express parvalbumin (PV), but not all — some express cholecystokinin (CCK). PV basket cells are typically fast spiking, and are thought to be important for gain control and for the temporal precision of network activity.

+
+
+
BCI task driven by one conditioned neuron conditionedneuronmouselickport ΔF/Fnear within 10 slearned in ~30 trials speed
+
STIMULUS
+

BCI task / conditioned neuron

+

A lickport moves toward the mouse at a speed set by the fluorescence of one chosen neuron. Reaching the near position within 10 s earns water. Mice usually learn to drive that neuron within about 30 trials.

+ +
+
+
DATA
+

Behavior session

+

One behavioural recording, whether it happened under the microscope or in the training facility. Its session_type names the training stage, which is how the full training history is reconstructed.

+
+
+
Bipolar cell + + + + + + + + + + +
+
CELLTYPE
+

Bipolar cell (BPC)

+

A subset of VIP cell with a bipolar dendritic arbor — two primary dendrites leaving opposite poles of the soma. Distinct from the retinal cell of the same name.

+
⚠ ambiguous
+
+
+
Blank sweep: mean-luminance trials interleaved with stimulitrial sequenceblankblanktimeeach stimulus gets its own baselineinterleaved, not blocked
+
STIMULUS
+

Blank sweep

+

A trial in which the stimulus is replaced by mean-luminance grey, interleaved among real trials so each stimulus has its own baseline.

+
+
+
+Bound Spatial Point + + + + +point + + + + + +pt_position + + +pt_supervoxel_id + + +pt_root_id +
+
TABLES
+

Bound Spatial Point

+

Binds an annotation to the cell at a location via the triad pt_positionpt_supervoxel_idpt_root_id.

+
+
+
Branch, end and root points on a skeletonpoint typeroot (soma)branchend
+
MORPH
+

Branch / End / Root point

+

Named skeleton vertex types; the root is conventionally placed at the soma.

+
+
+
STIMULUS
+

Catch trial / sham change

+

A change time is drawn but the image does not change. This conservative definition counts only presentations drawn from the change-time distribution; aborted trials are arguably catches too.

+ +
+
+
CAVE architecture hub + +imagery + +segmentation + +annotation DB + + + + + + + +CAVEclient +
+
CAVE
+

CAVE

+

Connectome Annotation Versioning Engine — the suite managing large dynamic connectomics data.

+
+
+
CAVE
+

CAVEclient

+

The main Python client for programmatic access to CAVE services. Servers: MICrONS global.daf-apis.com, V1DD global.em.brain.allentech.org.

+ +
+ +
+
Cell type dendrogram +all cells + +Excitatory +Inhibitory +Non-neuron + + + + +ITETCT +PvSstVip +AstOliMic + +
+
CELLTYPE
+

Cell type

+

Classification of a cell (e.g. 23P, BC) via several tables/methods, keyed on nucleus id.

+
+
+
+cell_id / soma_id + + +nucleus_id 302 (fixed) + + + + +…041 + +…582 + +…907 + + + + +v1 +v2 +v3 +root_id changes across versions +
+
TABLES
+

cell_id / soma_id

+

The 6-digit nucleus id (from nucleus_detection_v0), static across versions; tracks a cell over time.

+
+
+
cell_roi_id per session versus cell_specimen_id across a container day 1 day 2 day 3 roi 812roi 447roi 1903 cell_specimen_id matched across the container cell_roi_id — one experiment each
+
DATA
+

cell_specimen_id vs cell_roi_id

+

cell_roi_id identifies a segmented ROI within one experiment, before matching. cell_specimen_id identifies the cell after matching across sessions, and is therefore shared across a container. Joining on the wrong one silently loses the across-day link.

+
⚠ ambiguous
+
+
+
Change detection: lick when the image identity changes500 mslickwaterno lickgo / no-go, gap held in memory
+
STIMULUS
+

Change detection task

+

A go/no-go task: images are presented in a continuous stream and the mouse earns water by licking when the image identity changes. The 500 ms grey gap between images adds a working-memory component.

+ +
+
+
GENETIC
+

Channelrhodopsin (ChR2)

+

A light-gated ion channel used in optogenetics to control neuronal activity with light.

+
+
+
DATA
+

Channels table

+

One row per recording site, at general/extracellular_ephys/electrodes, with its position on the shank and in the CCF. A unit points into this table through its electrodes column; that is how a spike acquires a place in the brain.

+
+
+
GENETIC
+

ChRmine

+

A red-shifted opsin, excited near 1080 nm. Because GCaMP is excited near 920 nm the two can be driven independently, which is what makes simultaneous imaging and single-cell photostimulation possible.

+
+ +
+
Clean — proofreading status ladder + + + + + + + + + + +Extended + +Clean + +Unproofread + + +merge errors removed +
+
PROOF
+

Clean

+

Arbor proofread to remove all merge errors (synapses correct, but may be incomplete).

+
+ +
+
Column (MICrONS)L1L2/3L4L5L6piawhite matter100 µm census column
+
DATASETS
+

Column (MICrONS)

+

A 100 µm-square region spanning all cortical layers, densely proofread for a cell-type census.

+
MICrONS only⚠ ambiguous
+
+
+
Column (V1DD field)V1DD scan fields12345piaWMcf. MICrONS:samples onenarrow 100 µmslab5 sub-volumes tile the full depth
+
DATASETS
+

Column (V1DD field)

+

A column field naming one of 5 stacked scan sub-volumes tiling the V1DD block — a different concept from the MICrONS column.

+
V1DD only⚠ ambiguous
+
+
+
Common Coordinate Framework: one reference space for every modalityephysophysCCF[AP, DV, ML] µm
+
DATA
+

Common Coordinate Framework (CCF)

+

A standard 3D reference space for the mouse brain that lets data from different modalities be placed in the same coordinates.

+
+
+
Skeleton colored by SWC compartmentapicalbasalsomadendriteaxon
+
MORPH
+

Compartment labels

+

SWC integer codes: 0 undefined, 1 soma, 2 axon, 3 basal dendrite, 4 apical dendrite.

+
+
+
Connectivity ViewerConnectivity Viewer23PBC5P
+
TOOLS
+

Connectivity Viewer

+

Dash app showing a cell's synaptic inputs/outputs grouped and colored by cell type.

+
+
+
Connectomesynapsedirected edgeneuron
+
DATASETS
+

Connectome

+

A wiring map of neurons and the synaptic connections between them.

+
+
+
DATA
+

Container

+

There is no consistent use of this term.

+
⚠ ambiguous
+
+
+
STIMULUS
+

Context block

+

A ten-minute stretch in which only one modality is rewarded, signalled by instruction trials at its start. Blocks alternate for six blocks in a session.

+
⚠ ambiguous
+
+
+
Coordinate frames: voxel, nanometer, pia-flattenedx [4,4,40] nmtransformxyzxyzxyzvoxelnmpia-flat[i,j,k][x,y,z][u,v,d]
+
VOLUME
+

Coordinate frames

+

Three systems: voxel (annotations), nanometer (mesh/skeleton vertices), transformed (pia-flattened microns).

+
+
+
Coregistrationcalcium ROIEM somamatchagree
+
FUNCTION
+

Coregistration

+

Aligning functionally-imaged cells to the same cells in the EM volume (manual + automatic).

+
+
+
Cre line drives a loxP reporter STOPreporter loxPloxP Cre reporter STOP excised only in Cre+ cells
+
GENETIC
+

Cre line

+

Cre recombinase catalyses recombination between loxP sites. Paired with a loxP reporter line it drives the reporter's expression, and because Cre is expressed within a specific gene the expression is restricted to a subset of cells.

+
+
+
ctr_pt_position — synapse center pointaxondendritectr_pt_positionsynapse centroid, not root-bound
+
CONNECT
+

ctr_pt_position

+

The synapse-junction center point (not root-id-bound).

+
+
+
Current source density along the probe LFP by depth d2/dz2 source sink source sink marks synaptic input pia
+
SIGNAL
+

Current source density (CSD)

+

The second spatial derivative of the LFP along the probe, which localises current sinks and sources and so the laminar position of synaptic input.

+
+
+
QUALITY
+

d_prime (unit)

+

Separability of this unit's waveforms from its neighbours', by linear discriminant analysis. Higher is better. Not the behavioural d-prime.

+
⚠ ambiguous
+
+
+
STIMULUS
+

d-prime (behavioural)

+

Signal-detection sensitivity for the task: how far the hit rate exceeds the false-alarm rate. Not the unit quality metric of the same name.

+
⚠ ambiguous
+
+
+
Dash web appsTable ViewerConnectivity ViewerNeuroglancer
+
TOOLS
+

Dash web apps

+

Plotly-Dash apps (Table Viewer, Connectivity Viewer) for fast querying + Neuroglancer-link generation.

+
+
+
Datastack + + + +imagery + + + +segmentation + + + +annotations + +datastack +
+
CAVE
+

Datastack

+

A named bundle of imagery + segmentation + annotation DB (minnie65_public, v1dd_public).

+
+
+
QUALITY
+

decoder_label

+

The pipeline's automated call on what a unit is — sua for a single unit, and so on — with decoder_probability as its confidence.

+
+
+
QUALITY
+

Default quality filtering

+

Visual Coding applies isi_violations, amplitude_cutoff and presence_ratio filters by default; Visual Behavior Neuropixels returns every unit unfiltered. Same SDK, opposite defaults — check which you are holding.

+ +
+
+
QUALITY
+

default_qc

+

A single pass/fail flag summarising the pipeline's quality criteria for a unit, in the AIND-packaged datasets.

+
+
+
Depth axis: pia at top, white matter at bottom, y increases downwardpiawhite matter0+yy increasesdownwardinvert_yaxis
+
VOLUME
+

Depth / pia→WM axis

+

y increases with cortical depth, so depth plots need ax.invert_yaxis().

+
+
+
Digital twinstimulusDNNpredictedresponse
+
FUNCTION
+

Digital twin

+

A DNN trained to predict a cell's response to arbitrary stimuli (source of derived functional properties).

+
+
+
Direct versus indirect optotagging responses direct indirect under 10 ms, low jitter later, scattered every pulse via a synapse
+
GENETIC
+

Direct vs indirect activation

+

The central pitfall of optotagging: a neuron may respond to the laser because it expresses the opsin, or because a neuron that does synapses onto it. Direct responses are short-latency (<10 ms), reliable across pulses, and tightly distributed in time.

+ +
+
+
Distance: several senses for the same pair of pointspiadeptheuclideanalong the arborsame pair, different answers
+
DATA
+

Distance

+

Four geometric senses and two statistical ones are in routine use, and they give different answers for the same pair of points.

+
⚠ ambiguous
+
+
+
Drift metrics: extent versus total path of unit positionmax_driftµmsession timecumulative_drift = length of the path
+
QUALITY
+

Drift metrics

+

max_drift and cumulative_drift record how far, in µm, a unit's spikes moved along the probe during the session. Newer pipelines add activity_drift and drift_ptp.

+
⚠ ambiguous
+
+
+
Drifting grating: bars move orthogonal to their orientationdirectionorientationTF HzSF cyc/degcontrast2 s on1 s
+
STIMULUS
+

Drifting gratings

+

A full-field sinusoidal grating moving orthogonal to its own orientation. Parameters: orientation and direction (degrees), temporal frequency (Hz), spatial frequency (cycles/deg), contrast. Typically 2 s on, 1 s grey.

+ +
+
+
GENETIC
+

Driver line

+

A transgenic line engineered to label a specific cell population by expressing a gene under that population's promoter. The driver line determines which cells are targeted; the reporter line determines what is expressed in them.

+
+
+
DSIDSIone dominant direction
+
FUNCTION
+

DSI

+

Direction selectivity index (0–1).

+
+
+
Dynamic foraging: reward probabilities switch mid-sessionreward prob.LRblock switchlickschoose leftchoose right
+
STIMULUS
+

Dynamic foraging task

+

Two choices, binary reward, and reward probabilities that change during the session. A go cue opens a short window in which the mouse licks left or right; the mouse must learn from recent outcomes to track the better side.

+ +
+
+
Dynamic Routing: the same stimulus changes meaning by blockvisual blockauditory blockvisual blockGONO-GOGOsame stimulus, meaning set by block
+
STIMULUS
+

Dynamic Routing task

+

A context-dependent go/no-go task alternating visual and auditory blocks. The same stimulus is a target or not depending on the current block, so stimulus and meaning can be separated.

+
+
+
One highlighted edge between adjacent verticesedgevertex
+
MORPH
+

Edges

+

Pairs of connected vertices (mesh.edges, skeleton edges).

+
+
+
Electron microscopy (EM) + +e⁻ beam + + + + + + +thin section + + + + + + + +grayscale tile +
+
IMAGING
+

Electron microscopy (EM)

+

Imaging that reaches nanometer resolution to reveal tissue ultrastructure.

+
+
+
Encoding and decoding: same data, opposite directionstimulusactivityencodingdecoding
+
RESPONSE
+

Encoding vs decoding

+

Encoding asks whether an event changes neural activity; decoding asks whether the event can be read back out of the activity. Same data, opposite direction.

+
+
+
GENETIC
+

Enhancer AAV

+

A virus carrying a cell-type-specific enhancer, used to restrict expression without breeding a transgenic line.

+
+
+
CAVE
+

Environment secrets

+

How the CAVE auth token is supplied when code runs on a shared or hosted machine: exported as environment variables named API_SECRET_<server> instead of being written to a credentials file in the home directory.

+
+
+
MODALITY
+

Ephys

+

Shorthand for electrophysiology.

+
+
+
Ephys selection bias: large, fast-firing units dominateL2/3L4L6L5sorted: big, fast-firingmissed: sparsely activeL5 over-represented
+
RESPONSE
+

Ephys selection bias

+

Spike sorting needs enough spikes to form a cluster, so sparsely active neurons are missed and large-spike, high-rate neurons — and layer 5 — are over-represented. Ophys sees many of the cells ephys does not.

+ +
+
+
DATA
+

Epoch

+

A labelled stretch of time — but of what, and on whose clock, differs everywhere it appears.

+
⚠ ambiguous
+
+
+
Error profiles — axons vs dendrites + + + + + + + + + + + + + + +axons: more splits + + + + + + + + + + + + +dendrites: fewer errors +
+
PROOF
+

Error profiles

+

The characteristic ways automated segmentation fails, and how they differ by compartment: thin axons are dominated by split errors, thicker dendrites and somata by merges. This asymmetry is why proofreading status is tracked separately for axon and dendrite.

+
+
+
Event detection from delta F over F ΔF/F events L0 deconvolution 1-2 spikes: unreliable
+
SIGNAL
+

Event detection

+

Deconvolving ΔF/F into discrete events, here with the L0 method. At population imaging resolutions 1- and 2-spike events are detected unreliably, particularly with GCaMP6f.

+ +
+
+
RESPONSE
+

Evoked vs spontaneous

+

Activity driven by a stimulus versus activity during the grey-screen epochs. The comparison that decides whether a response is a response at all.

+
+
+
Excitatory V1 cell types by layer + + + + + + + + + + +L1L2/3L4L5L6WM + + + + + + + + + + + + + + + + + +23P4P5P6P + +
+
CELLTYPE
+

Excitatory V1 cell types

+

Pyramidal subclasses by layer/projection: 23P, 4P, 5P-IT/ET/NP, 6P-IT/CT (+ mtype clusters L2a…L6wm).

+
+
+
STIMULUS
+

Experience level

+

Whether the image set in a session is the one the mouse trained on (Familiar) or a different one (Novel). The axis the Visual Behavior datasets were built to test.

+
+
+
DATA
+

Experiment

+

There is no consistent use of this term. Establish which one is meant before joining anything.

+
⚠ ambiguous
+
+
+
Extended — proofreading status ladder + + + + + + + + + + + + + + + + + +Extended + +Clean + +Unproofread + + +fullest arbor +
+
PROOF
+

Extended

+

Arbor proofread to remove all merge AND split errors (correct and as-complete-as-possible).

+
+
+
Extracellular electrophysiology: spikes and local field potentialoutside the cellspikeslocal field potential
+
MODALITY
+

Extracellular electrophysiology

+

Recording voltage from outside the cell membrane, which gives better access to intact brains than intracellular recording. Its two readouts are spikes and the local field potential.

+ +
+
+
Eye tracking: ellipse fits to eye, pupil and corneal reflectionCReyepupilarea · centre · rotationlikely_blink
+
SIGNAL
+

Eye tracking / pupil

+

Ellipse fits to eye, pupil and corneal reflection per video frame, giving area, centre and rotation, plus a likely_blink flag. Recorded during physiology sessions but not during training.

+
+
+
One triangular face highlighted in a mesh patch1 facetriangle = 3 vertices + 3 edges
+
MORPH
+

Faces

+

Triangles of connected vertex indices that tile a mesh surface (mesh.faces).

+
+
+
Fast spiking narrow waveform versus broad waveform width narrow putative PV+ broad high rate no adaptation
+
CELLTYPE
+

Fast spiking neuron (FSN)

+

Narrow, fast action potentials; with enough injected current, high spike rates without frequency adaptation. In unlabelled extracellular recordings, narrow-waveform units are called fast spiking and putatively identified as PV+ cells.

+
+
+
FIBSEM vs serial-section TEM + +FIB-SEM + + + + + + +ion beam +mill block face in situ +ssTEM + + + + + + + + + + + +collect serial sections +context: FIB-SEM is destructive; sections stay archival +
+
IMAGING
+

FIBSEM

+

Focused-ion-beam SEM; block-face EM that mills & images, giving near-isotropic voxels.

+
adjacent method
+
+
+
MODALITY
+

Field of view

+

The imaged extent of one plane, in pixels and in µm. Recorded per experiment as field_of_view_width/height.

+
⚠ ambiguous
+
+
+
QUALITY
+

firing_rate

+

Mean spike rate over the whole session. Low values may mean a sparsely active neuron or a badly detected one.

+
+
+
GENETIC
+

Fluorophore

+

A molecule that absorbs light and re-emits it at a longer wavelength. Fluorophores fluoresce only while exposed to a light source.

+
+
+
Functional connectomecalcium (function)EM mesh (structure)same cells
+
DATASETS
+

Functional connectome

+

A dataset linking synapse-resolution EM connectivity to recorded neural function in the same neurons.

+
+
+
CELLTYPE
+

GABA

+

The main inhibitory neurotransmitter in the mammalian brain. In cortex most GABAergic neurons are local interneurons.

+
+
+
Gabor patches on a 9 by 9 grid of screen positions9 × 9 positions20° patch3 orientationssame every session
+
STIMULUS
+

Gabor patches

+

Spatially restricted gratings. The receptive-field mapping stimulus in Visual Coding Neuropixels: 20° diameter, three orientations on a 9 × 9 grid of screen positions, identical in every session.

+ +
+
+
GENETIC
+

GCaMP

+

A family of GECI fusing calmodulin's calcium-binding domain to green fluorescent protein. GCaMP6f and 6s are the fast and slow variants, differing in sensitivity and especially in decay kinetics.

+
+
+
GECI: fluorescence rises when the indicator binds calciumCa²⁺at rest, dimactive, brightΔF/F
+
GENETIC
+

Genetically-encoded calcium indicator (GECI)

+

A protein expressed by a cell that changes its fluorescence on binding Ca²⁺, used to visualise neural activity with fluorescence microscopy.

+
+
+
FUNCTION
+

Golden Mouse (409828)

+

The single V1DD mouse with functional coregistration.

+
V1DD only
+
+
+
FUNCTION
+

gOSI / gDSI

+

Global orientation/direction selectivity indices (vector-sum variant).

+
+
+
SEGMENT
+

Graphene (graphene://)

+

URL protocol for dynamic, CAVE-backed (editable) segmentation/meshes, vs static precomputed://.

+
+
+
Graphene vs Precomputed + + + +graphene:// +editable / live + + + +precomputed:// +frozen / static +
+
CAVE
+

Graphene vs Precomputed

+

graphene:// = dynamic/editable; precomputed:// = static.

+
+
+
Volume diced into a grid of chunks, one chunk highlightedchunkchunked volume
+
VOLUME
+

Grids / Chunk

+

The volume is partitioned into a 3D grid of chunks for the chunked-graph.

+
+
+
Head fixation: implanted bar clamped in a repeatable positionhead barclampclampsame position to < 10 µm
+
MODALITY
+

Head fixation / head bar

+

A surgically implanted bar clamps the mouse's head in a repeatable position — better than 10 µm across clamp cycles, which is what makes it possible to return to the same cells on a later day.

+ +
+
+
RESPONSE
+

Higher visual area (HVA)

+

A cortical visual area receiving input from primary visual cortex, and so higher in the visual hierarchy. In the mouse: VISl, VISal, VISpm, VISam, VISrl among others.

+
+
+
Hit, miss, false alarm and correct rejectlickno lickchangeshamhitmissfalse alarmcorrectreject750 ms response window
+
STIMULUS
+

Hit / miss / false alarm / correct reject

+

Lick within the 750 ms window after a change = hit; no lick after a change = miss; lick after a sham change = false alarm; withholding on a sham change = correct reject. Licking before the scheduled change aborts the trial.

+ +
+
+
STIMULUS
+

Image set

+

Which eight natural images a session used (G or H, A or B). Two images are shared between sets, so novelty is a property of the other six.

+
+
+
Imagery: grayscale EM tile + + + + + + + + + +8-bit grayscale tile + + + + + + + + +255 +0 +intensity +
+
IMAGING
+

Imagery

+

The 3D grayscale (0–255) array depicting EM ultrastructure.

+
+
+
Imaging depth below the cortical surfacepiaL2/3L4L5L60250350500planeCre line, not depth, gives layer specificity
+
MODALITY
+

Imaging depth

+

Depth in µm below the cortical surface at which a plane was collected. Roughly: <250 layer 2/3, 250–350 layer 4, 350–500 layer 5, >500 layer 6 — but layer-specific Cre lines are the reliable way to get layer specificity.

+ +
+
+
Imaging plane: one focal plane within a multi-plane stackup to 8planesone plane = one experimentsession = all planes together
+
MODALITY
+

Imaging plane

+

One two-photon focal plane. A single-plane microscope images one per session; the Multiscope/Mesoscope images up to eight. The plane, not the session, is what an ophys experiment is defined on.

+
+
+
Indicator sparsification: calcium boosts bursts and loses isolated spikesdF/Fburstsinglebursts boostedophysephystuning looks sharper
+
RESPONSE
+

Indicator sparsification

+

Calcium indicators respond non-linearly to firing rate: bursts are boosted, isolated spikes washed out. Tuning measured with ophys therefore looks sharper and sparser than the same tuning measured with ephys.

+ +
+
+
Inhibitory V1 cell types: manual vs targeting +manual +by morphology +targeting-based +by synaptic target + + + + + + + + + + + + + + + + + + + + + + + + + + + +BCBPCMCNGC +PTCDTCSTCITC + +
+
CELLTYPE
+

Inhibitory V1 cell types

+

Interneuron subclasses: BC, BPC, MC, NGC (manual) and PTC/DTC/STC/ITC (targeting-based mtypes).

+
+
+
CELLTYPE
+

Interneuron

+

A neuron with short axons that synapses only with nearby neurons. In cortex the term is often used to mean an inhibitory neuron.

+
+
+
MODALITY
+

Intrinsic signal imaging (ISI)

+

Measuring blood-flow changes from the reflectance of red light on the brain surface. Commonly used to map retinotopy across the cortical surface and so to target later recordings.

+
⚠ ambiguous
+
+
+
isi_violations: intervals shorter than the refractory period< refractoryISIspikes from two cells mergedthreshold 0.5
+
QUALITY
+

isi_violations

+

Rate of inter-spike intervals shorter than the refractory period. A real neuron cannot fire that fast, so violations mean spikes from more than one cell were merged. Default threshold 0.5.

+ +
+
+
QUALITY
+

isolation_distance

+

Distance in Mahalanobis space to the nearest other cluster of waveforms. Higher is better separated.

+
+
+
Excitatory projection classes and their targets + + + +L1L2/3L4L5L6L6b + + + + + + + + + + +IT cortex +NP local +CT thalamus +ET brainstem +SP subplate + +
+
CELLTYPE
+

IT / ET / NP / CT / SP

+

Projection categories: intratelencephalic, extratelencephalic, near-projecting, corticothalamic, subplate.

+
+
+
SIGNAL
+

Kilosort

+

The template-matching sorter used for all Allen Neuropixels data. It merges automatically, so no manual curation step is needed for recordings with little drift.

+ +
+
+
QUALITY
+

l_ratio

+

Contamination measure related to isolation distance: the probability that nearby spikes belong to this cluster. Lower is better.

+
+
+
Cortical layers from pia to white matter +pia + + + + + + + + + + + +cortical depth + +L1L2/3L4L5L6white matter + +
+
CELLTYPE
+

Layer (cortical)

+

L1–L6 along the pia→WM axis; drives cell-type naming. NOT the Neuroglancer layer.

+
⚠ ambiguous
+
+
+
Same neuron at coarse versus fine triangle densitycoarse~7 facesfine~40 faces
+
MORPH
+

Level of detail (LOD)

+

Static meshes are smaller, multi-LOD, precomputed://; dynamic meshes are detailed, single-LOD, graphene://.

+
+
+
Local field potential: summed activity of nearby cellsmany cells, one electrodesummed potentialbelow 250 Hz
+
SIGNAL
+

Local field potential (LFP)

+

Transient electrical potential generated in nervous tissue by the summed activity of the cells in it, typically measured below 250 Hz. Informative about oscillations and network synchrony.

+
+
+
Locally sparse noise with an exclusion zone 5 px bright dark no two spots within the zone
+
STIMULUS
+

Locally sparse noise

+

Black and white spots flashed on a grey screen, arranged so no two spots fall within 5 pixels of each other. The exclusion zone is what makes the average around any pixel structureless, so a receptive field can be recovered.

+ +
+
+
DATA
+

Manifest

+

The file a cache uses to know what data exists and where it was put. Instantiating a cache without naming one creates it in the working directory. There is no manifest when you read NWB directly; the file is the manifest.

+
+
+
Martinotti cell + + + + + + + + + + +
+
CELLTYPE
+

Martinotti cell (MC)

+

A subtype of SST cell that targets the apical dendrites of pyramidal cells in layer 1. Martinotti cells are found in layer 2/3 and layer 5.

+
+
+
Materialization and versioning + + +time + + +v1 + + +v2 + + +v3 + + +v4 +query @ v3 + + +
+
CAVE
+

Materialization & Versioning

+

Timestamped snapshots of the annotation DB; each version = a fixed timestamp (MICrONS v1507, V1DD v1196).

+
+
+
SIGNAL
+

Maximum / average projection

+

The imaging movie collapsed over time into one image — the standard way to see every cell in a plane at once.

+
⚠ ambiguous
+
+
+
Merge errors — false merge + + + + + + + + +false merge — adds a connection +
+
PROOF
+

Merge errors

+

Two neurons' processes incorrectly joined; they add false connections.

+
+
+
Neuron surface mesh with triangle-wireframe zoomsurface meshtriangles
+
MORPH
+

Meshes

+

Vertices + triangular faces defining a neuron's 3D outer surface.

+
+ +
+
MORPH
+

Meshpoints

+

Informal usage for mesh vertices. Not a formal term — say vertices, since “point” elsewhere means an annotation position.

+
⚠ ambiguous
+
+
+
MICrONSVISpVISalVISrl1 mm0.5 mmpiaWM3 visual areas · mm-scale EM volume
+
DATASETS
+

MICrONS

+

Cubic-millimeter functional-connectomics EM dataset of mouse visual cortex (VISp/VISal/VISrl).

+
+
+
DATASETS
+

Minnie

+

Internal name for the MICrONS dataset/mouse (minnie65; datastack minnie65_public).

+
+
+
SIGNAL
+

Motion correction

+

Registering every frame of the imaging movie to a reference before segmentation, so an ROI mask refers to the same cell throughout.

+
+
+
CELLTYPE
+

mtypes

+

Morphology/connectivity-derived cell-type clusters (L2a…L6wm; PTC/DTC/STC/ITC).

+
+
+
STIMULUS
+

Natural movies

+

Black and white film clips with natural spatial and temporal statistics — usually the opening shot of Touch of Evil, chosen because it is continuous, with no cuts and varied motion.

+ +
+
+
STIMULUS
+

Natural scenes

+

Black and white photographs with natural spatial statistics, flashed for 0.25 s with no gap. Visual Coding uses 118 images drawn from the Berkeley, van Hateren and McGill image sets.

+ +
+
+
Neuroglancerxyxzyz3D
+
TOOLS
+

Neuroglancer

+

WebGL browser viewer for very large volumetric connectomics data (imagery, segmentation, meshes, annotations).

+ +
+
+
TOOLS
+

Neuroglancer forks

+

Neuroglancer is maintained as several diverging branches. Spelunker is the one CAVE datastacks link to; the Seung-lab and FlyWire branches are the other widely used ones. States are broadly compatible but not identical.

+
⚠ ambiguous
+
+
+
Neuroglancer layers img seg annannsegimg
+
TOOLS
+

Neuroglancer Layer (img/seg/ann)

+

The data layers in a Neuroglancer state. NOT the cortical layer.

+
⚠ ambiguous
+
+
+
TOOLS
+

Neuroglancer State

+

JSON object storing all layers/view/annotations, identified by a state id.

+
+
+
Neurogliaform cell + + + + + + + + + + +
+
CELLTYPE
+

Neurogliaform cell (NGC)

+

An interneuron that makes a diffuse axonal arbor and is thought to release GABA through both synaptic release and volume transmission, non-selectively inhibiting nearby neurons.

+
+
+
Neuronal processdendritesomaaxon
+
SEGMENT
+

Neuronal process

+

An axon or dendrite branch of a neuron (a process that splits at branch points).

+
+
+
Neuropil correction: annulus signal subtracted from the ROI traceROI + annulusnearby cells excludedrawr × neuropil=corrected
+
SIGNAL
+

Neuropil correction

+

An annulus around the ROI, excluding nearby cells, gives a local neuropil signal. It is subtracted from the raw trace after weighting by a per-cell r value.

+ +
+
+
Neuropixels: dense electrode sites along one silicon shankone shank384 sitessorted unitshundreds per probe
+
MODALITY
+

Neuropixels

+

A family of silicon probes for high-channel-count single-unit extracellular recording, miniaturised with integrated-circuit design so that hundreds of units can be recorded from one probe with minimal brain damage.

+
+ + +
+
MORPH
+

Nodes

+

Vertices in the skeleton / L2 graph.

+
+
+
Neuropixels generations: site pitch and span1.020 µm2.015 µmUltra6 µmOpto+ light384 channels read at a time
+
MODALITY
+

NP 1.0 / 2.0 / Ultra / Opto

+

1.0: 960 sites, ~20 µm pitch, ~3.8 mm span. 2.0: 1280 sites per shank, ~15 µm pitch. Ultra: 6 µm pitch, fine detail over a shorter span. Opto: 1.0 plus 28 on-shank light emission sites. All read out 384 channels at a time.

+ +
+
+
NWB: one format, two storage backendsNWBone schemaHDF5one fileZarrchunked, cloud-read
+
DATA
+

NWB (Neurodata Without Borders)

+

The standard file format for physiology and behaviour data. Visual Coding and Visual Behavior use an HDF5 backend; the newer datasets — V1DD, BCI, Dynamic Foraging, NP Ultra — use a Zarr backend optimised for cloud access.

+
+
+
Where data live inside an NWB file session.nwb units intervals acquisition processing stimulus epochs sorted spikes trials raw timeseries derived signals what was shown when
+
DATA
+

NWB layout

+

Every NWB file has the same top-level groups: general (subject, devices, electrodes or imaging planes), acquisition (signals as acquired), stimulus (what was presented), intervals (epochs, trials, blocks), processing (anything derived), units (sorted units, ephys only) and analysis (non-standard extras). What differs between datasets is what fills them — and where a dataset puts a thing is not always where you would guess, so print the tree first.

+ +
+
+
An omitted stimulus presentation omission 5% time never at or just before a change
+
STIMULUS
+

Omission

+

5% of non-change presentations are dropped, interrupting the expected stimulus cadence so that expectation signals can be measured. Omissions occur during recording but not during training, and never at or just before a change.

+ +
+
+
MODALITY
+

Ophys

+

Shorthand for optical physiology, often in reference to two-photon calcium imaging, but can also include other methods such as fiber photometry.

+
+
+
Ophys container: one imaging plane followed across dayssame imaging planeday 1day 2day 3one containersession count varies with QC
+
DATA
+

Ophys container

+

The same imaging plane followed across days. Containers hold different numbers of sessions depending on which passed QC and how many retakes happened.

+
⚠ ambiguous
+
+
+
Ophys experiment: one imaging plane within a sessionsession175275375500experimentimaging_depth · targeted_structure
+
DATA
+

Ophys experiment

+

One imaging plane in one session — the narrowest unit in the hierarchy, with its own imaging_depth and targeted_structure. Quality control passes or fails each plane separately.

+
⚠ ambiguous
+
+
+
DATA
+

Ophys session

+

One continuous recording under the two-photon microscope. It contains one imaging plane on a single-plane scope and up to eight on the Multiscope.

+
+
+
Opsin: a light-gated ion channel in the membraneoutsideinsidelightionsexcitatoryinhibitorybar = illumination
+
GENETIC
+

Opsin

+

A light-gated ion channel. Illumination changes its conformation, letting ions cross the membrane and either forcing the cell to spike (excitatory opsin) or suppressing spiking (inhibitory).

+ +
+
+
GENETIC
+

Optogenetics

+

Controlling neural activity by expressing light-activated ion channels in a specific subpopulation — a reporter line for the opsin, a driver line for the population — giving temporally precise control of spiking.

+
+
+
Optotagging: tagged units follow the laser pulse train10 ms pulses · 20 Hztagged unituntagged unitspikes locked to pulses
+
GENETIC
+

Optotagging

+

Using optogenetics to identify which recorded units belong to a genetically defined population, by their response to laser pulses. Trains of 10 ms pulses at 20 Hz are a common stimulus.

+
+
+
FUNCTION
+

Oracle score

+

Visual-response reliability — signal correlation across repeated “oracle” movies.

+
+
+
OSIOSIsharpOSI ≈ 1broadOSI ≈ 0
+
FUNCTION
+

OSI

+

Orientation selectivity index (0–1).

+
+
+
CELLTYPE
+

Parvalbumin-positive (PV+) neuron

+

Fast-spiking GABAergic interneurons with strong inhibitory effects on their neighbours; action potentials can be under 400 µs. Parvalbumin is a calcium buffer, so calcium imaging of these cells should be read cautiously.

+
+
+
STIMULUS
+

Passive replay block

+

The same stimuli replayed with the lick spout retracted and no reward, so task-dependent modulation can be separated from stimulus drive.

+
+
+
Peak channel: the channel with the largest mean waveformlargestchannelsregion + depthpeak_channel_id
+
SIGNAL
+

Peak channel

+

The channel on which a unit's mean waveform is largest. A unit carries no position of its own — joining peak_channel_id to the channels table is how it acquires a CCF location, a brain-region label and a depth.

+ +
+
+
DATASETS
+

Physiology

+

The activity side of a functional-connectomics dataset: the calcium-imaging responses recorded from the same neurons that were later reconstructed in EM.

+
+
+
A position: point marker inside a voxel grid with (x, y, z) label(x, y, z)voxel grid
+
VOLUME
+

Position

+

The 3D coordinate of a bound spatial point (pt_position, stored in voxels by default).

+
+
+
CAVE
+

Precomputed format

+

Storage representation for arbitrarily large images/meshes/skeletons.

+
+
+
pref_dirθ90°180°270°pref_dir
+
FUNCTION
+

pref_dir

+

Preferred direction in degrees (0–360; 0 = vertical bar moving right, CCW+).

+
+
+
pref_oriθpref_oriθ ∈ 0–180°
+
FUNCTION
+

pref_ori

+

Preferred orientation in degrees (0–180).

+
+
+
Presence ratio across the session unit A 0.98 keep unit B 0.42 drifted no spikes after drift session threshold 0.9
+
QUALITY
+

presence_ratio

+

Fraction of the session in which the unit had spikes. A low value usually means the unit drifted away from the probe. Default threshold 0.9.

+ +
+
+
Probe, shank, site and channel probe shank site channel wired out now sites patterned on each shank
+
MODALITY
+

Probe / shank / channel / site

+

The recording hierarchy: a probe carries one or more shanks, a shank is patterned with recording sites, and the subset wired out for recording at any moment are the channels.

+
+
+
Project cache: remote store to local directory to tablesremote storemanifest tablessession objectscache_dirdownloads once
+
DATA
+

Project cache

+

The AllenSDK entry point for the Brain Observatory datasets: it downloads what you ask for, keeps it in a known directory, and hands back manifest tables and session objects. Newer datasets have no cache — you open the NWB file yourself.

+
+
+
Proofreading — before and after + + + + + + + + + + + +merge + split + + +proofread + + + + + + + + + +one clean neuron +
+
PROOF
+

Proofreading

+

Manual correction of split/merge errors to make neurons biologically accurate/complete.

+
+
+
Peri-stimulus time histogram onset trials rate binned and averaged over trials
+
RESPONSE
+

PSTH

+

Peri-stimulus time histogram: spikes binned relative to stimulus onset and averaged over trials, giving the time course of the response.

+
+
+
PyChunkedGraph L2 graphL2 nodes ~10supervoxels 1e3voxels 1e6
+
SEGMENT
+

PyChunkedGraph (PCG) / L2 graph

+

Hierarchical representation: L0 = voxels, L1 = supervoxels, L2 = supervoxels grouped within a chunk.

+
+
+
CELLTYPE
+

Pyramidal cell

+

An excitatory neuron with a characteristic cell-body shape and apical dendrite. In visual cortex, by far the most common excitatory type.

+
+
+
Q value and reward prediction error fitted to foraging behaviourchoicerewardbehaviourQ valueRPERL model fitneural activitylatent variables become regressors
+
STIMULUS
+

Q value / RPE

+

Latent variables of a reinforcement-learning fit to foraging behaviour: the expected value of each choice, and the reward prediction error that updates it. Useful precisely because they can then be regressed against neural activity.

+
+
+
TABLES
+

query_table / synapse_query

+

The two query entry points + filter_in_dict; note the 200k-row cap, desired_resolution, select_columns, split_positions.

+
+
+
Skeleton segment as tapering tube with radius calloutr = 1.2 µmradius per skeleton vertex
+
MORPH
+

Radius

+

Half the cable thickness at a skeleton vertex (µm).

+
+
+
FUNCTION
+

readout_loc_x/y

+

Approximate receptive-field center in stimulus space.

+
+
+
Receptive field: only stimuli inside the region drive the cellresponseno responsestimulus insidestimulus outside
+
RESPONSE
+

Receptive field

+

The region of the stimulus domain in which a stimulus must lie to evoke a response. Generalises beyond space to any stimulus dimension, and so to the stimulus features that drive a cell.

+
+
+
+Reference table + +cells + + + + + +pos + + +id +7 +8 + +cell_type + + + + + + +id +7 +8 +type_ref +exc +inh +join on id + + + +adds *_ref columns +
+
TABLES
+

Reference table

+

A table linked to another (usually nucleus_detection_v0) by shared annotation id, adding _ref columns.

+
+
+
CELLTYPE
+

Regular spiking neuron (RS)

+

Longer action potentials and spike-frequency adaptation — the rate falls over a sustained current step. The most common cortical type, usually associated with excitatory pyramidal neurons.

+
+
+
GENETIC
+

Reporter line

+

A transgenic line engineered to express a protein that monitors or manipulates activity — GFP, GCaMP, channelrhodopsin — but only once the controlling protein (Cre or FLP) is present.

+
+
+
Residual and separation scorecoreg matchresidual2.1 µmseparation0.92
+
FUNCTION
+

Residual / Separation score

+

The two coregistration-quality metrics.

+
+
+
VOLUME
+

Resolution

+

Physical voxel size in nm/voxel (MICrONS 4×4×40; V1DD 9×9×45); set per query via desired_resolution.

+
+
+
STIMULUS
+

Response modulation index (RMI)

+

The normalised contrast between visual and auditory target response rates, collapsing two hit rates into one number that says which context the mouse is behaving in.

+
+
+
DATA
+

Retake

+

A second attempt at a session_type after the first failed QC. Why prior_exposures_to_image_set and not session_type tells you whether a session was truly the first with novel images.

+
+
+
Retinotopy: neighbouring points in visual space map to neighbouring cortexmaps toazimuthaltitudevisual fieldcortex
+
RESPONSE
+

Retinotopy

+

The mapping of visual space onto neural space: neighbouring points in the visual field are represented by neighbouring points in the brain. Measured as altitude (upper–lower) and azimuth (left–right).

+
+
+
ROI mask: the pixels assigned to one segmented cellimaging plane, pixel gridmaskone ROI = pixels of one cell
+
SIGNAL
+

ROI mask

+

The pixel mask for one segmented cell in an imaging plane. In two-photon data an ROI is the set of pixels thought to belong to a single neuron.

+
+
+
Root ID (pt_root_id)pt_root_id864691135…changes with every edit
+
SEGMENT
+

Root_id (pt_root_id)

+

Unique integer for a specific segmentation = a specific version of a cell (a.k.a. segment / object id).

+
+
+
Running speed aligned sample-for-sample with the activity tracestimulus epochrunning speedcm/sΔF/Fsame time index in both
+
SIGNAL
+

Running speed

+

Speed on the running disc, temporally aligned to the activity traces. Same length as ΔF/F, so a stimulus epoch indexes into both.

+
+
+
CELLTYPE
+

Saccade

+

A rapid ballistic eye movement between fixation points. Mice are not foveal animals and their eye movements differ from those of foveal species.

+
+
+
ScanROI identityscan_idxsessionunit_id++unique ROI
+
FUNCTION
+

Scan

+

The scan_idx from functional imaging; part of the ROI's unique id.

+
+
+
SegmentationEM tileby object id
+
SEGMENT
+

Segmentation

+

A 3D array where each voxel stores the root_id of the object at that location.

+
+
+
SEGMENT
+

Segments (= root/object id)

+

“Segment id” used as a synonym for root id — collides with the skeleton sense of “segment”.

+
⚠ ambiguous
+
+
+
One unbranched skeleton segment highlightedsegmentunbranched pathbetween nodes
+
MORPH
+

Segments (skeleton)

+

An unbranched run of vertices between branch/end points.

+
⚠ ambiguous
+
+
+
Serial-section EM + + + + + + +sections peel off + + +align + + + + + + + + + + + + +fine x/y + + +coarse z +re-aligned stack +
+
IMAGING
+

Serial-section EM

+

Many ultrathin sections are cut from a block, imaged one by one, then re-aligned into a volume. Resolution is fine in x/y and coarse in z, so voxels are strongly anisotropic.

+
+
+
SessionROI identityscan_idxsessionunit_id++unique ROI
+
DATA
+

Session

+

The databook defines it as “a physiological and/or behavioral recording that happens at one time”, but four narrower senses are in use as identifiers.

+
⚠ ambiguous
+
+ +
+
Signal correlation across conditions versus noise correlation within a conditionsignalstimulus conditionsame preferences?noisecell A, trial by trialfluctuate together?two cells, two questions
+
RESPONSE
+

Signal vs noise correlation

+

Signal correlation compares two cells' mean responses across stimulus conditions — do they like the same things. Noise correlation compares their trial-to-trial fluctuations to the same condition — do they vary together.

+
+
+
SIGNAL
+

Single unit vs multi-unit

+

Not two categories but a gradient, from complete and uncontaminated to incomplete and highly contaminated. Every analysis still has to draw a binary line somewhere; quality metrics are how you draw it deliberately.

+ +
+
+
Cartoon neuron reduced to a skeletonskeletonizeneuronskeleton
+
MORPH
+

Skeletons

+

Tree-like linear representation of a neuron's branching (vertices + edges, radius, compartments).

+
+
+
QUALITY
+

snr

+

Waveform amplitude relative to background noise on the peak channel.

+
⚠ ambiguous
+
+
+
CELLTYPE
+

Somatostatin (SST) cell

+

An inhibitory interneuron expressing somatostatin (SST, sometimes SOM). SST cells tend to target the distal dendrites of excitatory neurons, and have important roles in regulating their activity.

+
+
+
TABLES
+

Source

+

Disambiguation: image_source/segmentation_source, the Neuroglancer layer source, and skeleton path_between(source,…).

+
⚠ ambiguous
+
+
+
Source (presynaptic)targetprepresynaptic source
+
CONNECT
+

Source (presynaptic)

+

The presynaptic partner of a synapse (pre_pt_root_id).

+
+
+
RESPONSE
+

Spatial frequency

+

How often the sinusoidal components of a signal repeat per unit distance — for a grating, the spacing of its bars. Typically cycles per degree.

+
+
+
Spike band and LFP band split from the same channelspike band30 kHz · high-pass 500 HzLFP band2.5 kHz · low frequency
+
MODALITY
+

Spike band / LFP band

+

The two streams split off each channel: the spike band at 30 kHz with a 500 Hz high-pass, carrying action potentials from adjacent neurons; the LFP band at 2.5 kHz, carrying low-frequency fluctuations from a wider area.

+ +
+
+
Spike raster: one row per trial, one tick per spikeeventtrialtimealigned on each trial
+
RESPONSE
+

Spike raster

+

One row per trial, one tick per spike, aligned on an event. The plot to make before any model, because it shows trial-to-trial structure that an average hides.

+
+
+
Spike sorting: waveforms to clusters to refractory check waveformsfeaturesISI check refractory gap one cluster per neuron
+
SIGNAL
+

Spike sorting

+

Assigning detected spikes to individual neurons — a blind source separation problem. Detection, extraction, feature extraction, clustering, then validation against the refractory period.

+ +
+
+
Split errors — false split + + + + + + + + + + + + + + + + +false split — removes a connection +
+
PROOF
+

Split errors

+

A process incorrectly appears to stop; they remove true connections.

+
+
+
STIMULUS
+

Spontaneous activity

+

An epoch of mean-luminance grey with no patterned stimulus, included in most sessions as a baseline for visually evoked activity.

+
+ +
+
DATA
+

State

+

Four unrelated meanings, two of which appear in the same workshop.

+
⚠ ambiguous
+
+
+
Static gratings: phase replaces temporal frequencyphase 0phase shiftedflashed 0.25 sno temporal frequency
+
STIMULUS
+

Static gratings

+

A stationary full-field sinusoidal grating flashed for 0.25 s. No temporal frequency; phase becomes a parameter instead.

+ +
+
+
Status flags — per-compartment badges + + + + + + +cell +status_axon + + +status_dendrite + + +
+
PROOF
+

Status flags

+

Booleans status_axon/status_dendrite recording whether each arbor was proofread, plus valid_id (root id at assessment).

+
+
+
DATA
+

Stimulus epoch table

+

When each interleaved stimulus block began and ended. In Visual Coding 2P the bounds are given as imaging frames, so they index directly into the ΔF/F and running-speed traces.

+
+
+
Stimulus presentations table: one row per stimulus shownstart_timestop_timeimageis_change31.531.8im065False32.332.6im065False33.834.1im012False33.033.3im012Trueone row per presentationevery alignment starts here
+
DATA
+

Stimulus presentations table

+

One row per stimulus shown, with its parameters and its start_time and stop_time. The table every alignment starts from. In NWB it lives under stimulus/presentation, or as a TimeIntervals table under intervals — which one depends on the dataset.

+
+
+
STIMULUS
+

Stimulus template

+

The literal image shown, stored alongside the stimulus table for image and movie stimuli. Often available both unwarped and warped — the warped version is what the monitor rendered.

+
+
+
PROOF
+

Strategy values

+

dendrite_clean, dendrite_extended, axon_partially_extended, axon_fully_extended, axon_interareal (MICrONS only), none.

+
+
+
DATA
+

Structure acronym

+

The CCF region label attached to a channel or unit — VISp, MOs, LSr. A unit with no CCF registration gets coordinates of [-1, -1, -1].

+
+
+
Supervoxelsv1sv2sv3voxel gridvoxels merged into supervoxels
+
SEGMENT
+

Supervoxel (pt_supervoxel_id)

+

L1 grouping of voxels within a chunk; the stable internal id an annotation binds to.

+
+
+
Surround suppression by a large grating within RF beyond RF response suppressed stronger in superficial layers
+
RESPONSE
+

Surround suppression

+

A stimulus extending beyond a cell's classical receptive field suppresses its response. Stronger in superficial layers, and one of the questions V1DD's windowed and full-field gratings were designed to address.

+
+ +
+
Synapse size — small vs large cleftsmall3 voxlarge7 vox
+
CONNECT
+

Synapse size

+

Synapse size in voxels; correlates with surface area / strength.

+
+
+
synapse_target_predictions_ssa — soma, spine, shaftaxonsomaspineshaft
+
CONNECT
+

synapse_target_predictions_ssa

+

Per-synapse postsynaptic-compartment prediction (soma / spine / shaft).

+
+ +
+
Table Viewerfilterstypelayerview in Neuroglancer
+
TOOLS
+

Table Viewer

+

Dash app to query/filter one table and select rows in Neuroglancer.

+
+
+
+Tables + + + +synapses + + + + + + + +nuclei + + + + + + + +cell types + + + + + + + +proofread + + + + + + + +coreg + + + + +
+
TABLES
+

Tables

+

CAVE annotation tables (synapses, nuclei, cell types, proofreading, coregistration).

+
+
+
Tags and shortcutskeytagsadsynapseaxondendrite
+
TOOLS
+

Tags / Shortcuts

+

Keyboard-driven annotation labels for fast bulk labeling in Neuroglancer.

+
+
+
TABLES
+

Target

+

Disambiguation: target_id (reference link) vs synaptic postsynaptic partner vs path target_index.

+
⚠ ambiguous
+
+
+
Target (postsynaptic)prepostpostsynaptic target
+
CONNECT
+

Target (postsynaptic)

+

The postsynaptic partner of a synapse (post_pt_root_id).

+
+
+
MORPH
+

TEASAR

+

Algorithm that turns the L2 graph into a skeleton tree.

+
+
+
IMAGING
+

TEM

+

Transmission EM; MICrONS/V1DD are serial-section TEM-style (thin sections, anisotropic z).

+
adjacent method
+
+
+
RESPONSE
+

Temporal frequency

+

How many complete periods the signal goes through per unit time. Typically Hz.

+
+
+
MODALITY
+

Three-photon (3P) imaging

+

Raises signal-to-noise for deep imaging of densely labelled tissue. Used to extend the V1DD centre column to white matter, where 2P image quality has degraded.

+
+
+
Token and authentication + + + + + +key + +token + + + + + + + + +server + + +
+
CAVE
+

Token / auth

+

Google-account credential required before any programmatic access, saved per server.

+
+
+
GENETIC
+

Transgenic line

+

A mouse line whose genome has been altered by introducing foreign DNA. Here, typically a Cre line driving expression of a reporter line within a specific subset of cells.

+
+
+
DATA
+

Trials table

+

One row per trial: timing landmarks and outcome flags. Usually nwb.intervals['trials'], but not always — the BCI dataset keeps its trials under stimulus/presentation, because there the lickport is driven by the neuron. And a “trial” is not always behavioural: in the cell-type look-up table it is a laser pulse train.

+
+
+
Tuning curve: mean response against a stimulus parameterpreferred0360direction (°)mean response
+
RESPONSE
+

Tuning curve

+

Mean response plotted against a stimulus parameter. The shape of the curve is what selectivity indices such as OSI and DSI summarise in one number.

+
+
+
Two-photon calcium imaging: a spike raises indicator fluorescenceCa²⁺spikecalcium influxfluorescence
+
MODALITY
+

Two-photon calcium imaging

+

Measuring neural activity through a fluorescent calcium indicator such as GCaMP. At rest a neuron has low calcium; when it spikes, calcium flows in, binds the indicator and raises the emitted fluorescence.

+
+
+
Two-photon excitation is confined to the focal volume one photon two photons excited along the cone excited at the focus only linear non-linear in photon density
+
MODALITY
+

Two-photon excitation

+

Two long-wavelength photons excite one fluorophore. Absorption is non-linear in photon density, so only a single voxel is excited at a time — that is what gives optical sectioning in intact tissue.

+ +
+
+
Types of errors in imagery + + + + + +fold + + + + +crack + + + + + + + + +dropped +
+
IMAGING
+

Types of errors in imagery

+

Section/alignment artifacts (folds, cracks, missing sections) that propagate into segmentation.

+
+
+
Ultrastructure + + + + +mitochondrion + + + + + + + +synaptic vesicles + + + + + +myelin + + + +membrane +
+
IMAGING
+

Ultrastructure

+

Fine sub-cellular EM features: organelles, mitochondria, synapses, myelin.

+
+
+
UnitROI identityscan_idxsessionunit_id++unique ROI
+
DATA
+

Unit

+

Two different recording modalities use this word for their basic recorded element, and they are not the same thing.

+
⚠ ambiguous
+
+
+
Unit quality metrics: contamination, missed spikes, driftcontaminationspikes missedunit drifts awaythresholds depend on the analysis
+
QUALITY
+

Unit quality metrics

+

Per-unit numbers describing how badly spike sorting may have gone wrong for that unit — contamination from other neurons, spikes missed, or the unit drifting away. None is perfect; which thresholds apply depends on the analysis.

+ +
+
+
DATA
+

Units table

+

One row per sorted unit: spike times, mean waveform, quality metrics, and the peak channel that gives it a location. The primary table of any ephys dataset.

+ +
+
+
Unproofread — proofreading status ladder + + + + + + + + + + + + + +Extended + +Clean + +Unproofread + + +incomplete arbor +
+
PROOF
+

Unproofread

+

An arbor that has not been comprehensively corrected. It is truncated by split errors and may carry merged fragments of other cells, so its apparent partners are unreliable.

+
+
+
V1DD (V1 Deep-Dive)800 µm800 µmpiaWMcortical depth×4 mice
+
DATASETS
+

V1DD (V1 Deep-Dive)

+

Functional (2p/3p calcium) + EM dataset of V1 across all layers in 4 mice (~50k neurons/mouse).

+
V1DD only
+
+
+
FUNCTION
+

V1DD functional index

+

V1DD's Golden-Mouse column/volume/plane/roi scheme, distinct from MICrONS session/scan/unit.

+
V1DD only
+
+
+
QUALITY
+

valid_roi

+

The ophys equivalent of a unit quality flag: whether cell classification judged a segmented ROI to be a real cell. Only valid ROIs are released.

+
+
+
Vertices tracing a neuron outlinevertex3D points sampling the surface
+
MORPH
+

Vertex / Vertices

+

Points in 3D (N×3, nanometers) that, connected, build meshes and skeletons.

+
+
+
CELLTYPE
+

VIP cell

+

An inhibitory interneuron expressing Vasoactive Intestinal Protein. VIP cells tend to target somatostatin cells rather than excitatory neurons; this role as a “disinhibitory specialist” is thought to matter for context-dependent modulation of cortical activity.

+
+
+
Mouse visual area flat-map patch + + + + + + + +V1 +VISp +RL +VISrl +AL +VISal +LM +VISl + +A +L +
+
CELLTYPE
+

VISp / VISal / VISrl

+

The visual cortical areas (V1 / AL / RL / LM) the volume spans and assigns.

+
+
+
Cortical EM volume with a zoom-in to a single voxelEM volume1 voxel
+
VOLUME
+

Volume

+

A cubic-mm 3D EM image dataset spanning a cortical region.

+
+
+
PROOF
+

VORTEX

+

NIH program (Virtual Observatory of the Cortex) funding continued proofreading; source of the vortex_* tables.

+
+
+
Voxel: anisotropic, z ~10x coarser than x and y4 nm4 nm40 nm
+
VOLUME
+

Voxel

+

The smallest 3D image unit; anisotropic 4×4×40 nm (MICrONS) / 9×9×45 nm (V1DD).

+
+
+
Mesh hole flagged as not watertighthole⚠ not watertight
+
MORPH
+

Watertight

+

EM meshes are NOT watertight, so Trimesh .volume/.center_mass are invalid.

+
+
+
Spike waveform: trough and repolarisation peak of the mean spiketroughpeakµV~3 mssingle spikesmean waveform
+
SIGNAL
+

Waveform

+

The voltage over time measured at an electrode when a neuron fires an action potential. The per-unit mean waveform is what the shape metrics are computed from.

+
+
+
ΔF/F: fluorescence normalised by a rolling baselineraw FF₀180 s windowΔF/F(F − F₀) / F₀
+
SIGNAL
+

ΔF/F (dF/F)

+

Change in fluorescence normalised by a baseline. The baseline is the median fluorescence in a 180 s window centred on each time point, so ΔF/F is a relative, unitless signal.

+ +
+
+ + + +

+ Generated from the Allen Glossary + (revision 2026-08), which is the source of truth for these definitions — + corrections and new terms belong there, not on this page.
Further reading: MICrONS Explorer · CAVEclient documentation · NWB · AIND open data on S3 +

+ +
+ + +::::: + +## Term index + +The same 249 terms as a plain list, A to Z. This is what the databook's own +search box and any `{term}` cross-reference elsewhere in the book resolve against, +so it is folded away rather than left out. + +::::::{dropdown} Every term, A to Z +:::::{glossary} +3D reconstruction + Turning EM imagery into 3D neuron objects (dense segmentation → meshes). Go to the card. + Action potential - A characteristic signal that appears in excitable cell membranes, which takes the - form of an electric potential difference waveform that propagates down the length - of the cell membrane. In neurons, these indicate neuron activation. See {term}`Spike`. +Spike + A characteristic signal in excitable cell membranes: a potential-difference waveform that propagates along the membrane. In neurons it indicates activation. The trace is a Hodgkin-Huxley simulation: a brief current pulse opens sodium channels, which depolarise the membrane and then inactivate, while potassium conductance rises more slowly and repolarises it past rest. Go to the card. +AIND metadata schema + Six JSON classes describing a newer data asset: data description, subject, procedures, rig or instrument, session or acquisition, and processing. Where you look up which virus was injected, or what a capsule actually ran. Go to the card. + +AllenSDK + The Python package for the Brain Observatory physiology datasets, wrapping downloads and metadata behind a cache object. Being retired in favour of reading NWB files directly, so new work should not start here. Go to the card. + +amplitude_cutoff + Estimated fraction of the unit's spikes that fell below the detection threshold and were never recorded — a false-negative rate. Default threshold 0.1. Go to the card. + +Annotation + Labeled data (points/tables) bound to locations or cells in the volume. Go to the card. + +Baiting / coupled vs uncoupled + Baiting: a reward an unchosen side would have given is held and delivered on the next choice of that side. Coupled or uncoupled describes whether the two sides' probabilities change together or independently. Go to the card. + +Basket cell (BC) Basket cell - A type of inhibitory neuron whose synaptic output targets the cell body and - proximal dendrites of excitatory neurons. Many basket cells express the - molecular marker parvalbumin (PV), but not all basket cells are PV+: some - express molecules such as cholecystokinin (CCK). PV basket cells are typically - fast spiking compared to other neurons and are thought to be important for - gain control of network activity and setting the temporal precision of network - activity. + Inhibitory neuron whose synaptic output targets the cell body and proximal dendrites of excitatory neurons. Many basket cells express parvalbumin (PV), but not all — some express cholecystokinin (CCK). PV basket cells are typically fast spiking, and are thought to be important for gain control and for the temporal precision of network activity. Go to the card. + +BCI task / conditioned neuron + A lickport moves toward the mouse at a speed set by the fluorescence of one chosen neuron. Reaching the near position within 10 s earns water. Mice usually learn to drive that neuron within about 30 trials. Go to the card. +Behavior session + One behavioural recording, whether it happened under the microscope or in the training facility. Its session_type names the training stage, which is how the full training history is reconstructed. Go to the card. + +Bipolar cell (BPC) Bipolar cell - A subset of VIP cell with a bipolar dendritic arbor. See {term}`VIP cell`. + A subset of VIP cell with a bipolar dendritic arbor — two primary dendrites leaving opposite poles of the soma. Distinct from the retinal cell of the same name. Go to the card. + +Blank sweep + A trial in which the stimulus is replaced by mean-luminance grey, interleaved among real trials so each stimulus has its own baseline. Go to the card. -BCI -Brain Computer Interface - A method of controlling a computer signal through the activity of a neuron. This can be extended to other types of devices (e.g. joysticks or robotic arms). This is also often referred to as "Brain Machine Interface" +Bound Spatial Point + Binds an annotation to the cell at a location via the triad pt_position → pt_supervoxel_id → pt_root_id. Go to the card. +Branch / End / Root point + Named skeleton vertex types; the root is conventionally placed at the soma. Go to the card. + +Catch trial / sham change + A change time is drawn but the image does not change. This conservative definition counts only presentations drawn from the change-time distribution; aborted trials are arguably catches too. Go to the card. + +CAVE + Connectome Annotation Versioning Engine — the suite managing large dynamic connectomics data. Go to the card. + +CAVEclient + The main Python client for programmatic access to CAVE services. Servers: MICrONS global.daf-apis.com, V1DD global.em.brain.allentech.org. Go to the card. + +cc_abs / cc_max / cc_norm + Digital-twin model-performance columns. Go to the card. + +Cell type + Classification of a cell (e.g. 23P, BC) via several tables/methods, keyed on nucleus id. Go to the card. + +cell_id / soma_id + The 6-digit nucleus id (from nucleus_detection_v0), static across versions; tracks a cell over time. Go to the card. + +cell_specimen_id vs cell_roi_id + cell_roi_id identifies a segmented ROI within one experiment, before matching. cell_specimen_id identifies the cell after matching across sessions, and is therefore shared across a container. Joining on the wrong one silently loses the across-day link. Go to the card. + +Change detection task + A go/no-go task: images are presented in a continuous stream and the mouse earns water by licking when the image identity changes. The 500 ms grey gap between images adds a working-memory component. Go to the card. + +Channelrhodopsin (ChR2) + A light-gated ion channel used in optogenetics to control neuronal activity with light. Go to the card. + +Channels table + One row per recording site, at general/extracellular_ephys/electrodes, with its position on the shank and in the CCF. A unit points into this table through its electrodes column; that is how a spike acquires a place in the brain. Go to the card. + +ChRmine + A red-shifted opsin, excited near 1080 nm. Because GCaMP is excited near 920 nm the two can be driven independently, which is what makes simultaneous imaging and single-cell photostimulation possible. Go to the card. + +classification_system column + The E / I / non-neuron grouping column in cell-type tables. Go to the card. + +Clean + Arbor proofread to remove all merge errors (synapses correct, but may be incomplete). Go to the card. + +cloud-volume / ImageryClient + Serverless clients to read Precomputed imagery/segmentation and download aligned cutouts. Go to the card. + +Column (MICrONS) +Minnie column + A 100 µm-square region spanning all cortical layers, densely proofread for a cell-type census. Go to the card. + +Column (V1DD field) + A column field naming one of 5 stacked scan sub-volumes tiling the V1DD block — a different concept from the MICrONS column. Go to the card. + +Common Coordinate Framework (CCF) CCF -Common Coordinate Framework - The [CCF](background/CCF.md) is a a standard 3D reference space for the mouse brain that enables spatial integration of data across modalities. + A standard 3D reference space for the mouse brain that lets data from different modalities be placed in the same coordinates. Go to the card. + +Compartment labels + SWC integer codes: 0 undefined, 1 soma, 2 axon, 3 basal dendrite, 4 apical dendrite. Go to the card. + +Connectivity Viewer + Dash app showing a cell's synaptic inputs/outputs grouped and colored by cell type. Go to the card. -ChR2 -Channelrhodopsin - A light-gated ion channel used in the field of optogenetics to control neuronal activity with light. +Connectome + A wiring map of neurons and the synaptic connections between them. Go to the card. Container - *There is no consistent use of this term* - Most often this refers to the set of recording sessions for a single ophys imaging plane, but can also refer to the set of sessions for an animal. + There is no consistent use of this term. Go to the card. + +Context block + A ten-minute stretch in which only one modality is rewarded, signalled by instruction trials at its start. Blocks alternate for six blocks in a session. Go to the card. + +Coordinate frames + Three systems: voxel (annotations), nanometer (mesh/skeleton vertices), transformed (pia-flattened microns). Go to the card. + +Coregistration + Aligning functionally-imaged cells to the same cells in the EM volume (manual + automatic). Go to the card. Cre line - The Cre-lox system is a site-specific recombinase technology. Cre-recombinase - is a tyrosine site-specific recombinase that catalyzes the recombination of - DNA between specific sites known as loxP sequences. As used in these - experiments, Cre is used with loxP {term}`Reporter line` in order to drive - recombinase of the loxP sites and drive the expression of the reporter. As Cre - is often expressed within a specific gene, this allows the reporter expression - to be restricted to particular subset of cells. For specific lines used, see - the section on [transgenic tools](background/transgenic-tools.md). - -Dataset - *There is no consistent use of this term* + Cre recombinase catalyses recombination between loxP sites. Paired with a loxP reporter line it drives the reporter's expression, and because Cre is expressed within a specific gene the expression is restricted to a subset of cells. Go to the card. + +ctr_pt_position + The synapse-junction center point (not root-id-bound). Go to the card. + +Current source density (CSD) + The second spatial derivative of the LFP along the probe, which localises current sinks and sources and so the laminar position of synaptic input. Go to the card. + +d_prime (unit) + Separability of this unit's waveforms from its neighbours', by linear discriminant analysis. Higher is better. Not the behavioural d-prime. Go to the card. + +d-prime (behavioural) + Signal-detection sensitivity for the task: how far the hit rate exceeds the false-alarm rate. Not the unit quality metric of the same name. Go to the card. + +Dash web apps + Plotly-Dash apps (Table Viewer, Connectivity Viewer) for fast querying + Neuroglancer-link generation. Go to the card. + +Datastack + A named bundle of imagery + segmentation + annotation DB (minnie65_public, v1dd_public). Go to the card. + +decoder_label + The pipeline's automated call on what a unit is — sua for a single unit, and so on — with decoder_probability as its confidence. Go to the card. + +Default quality filtering + Visual Coding applies isi_violations, amplitude_cutoff and presence_ratio filters by default; Visual Behavior Neuropixels returns every unit unfiltered. Same SDK, opposite defaults — check which you are holding. Go to the card. + +default_qc + A single pass/fail flag summarising the pipeline's quality criteria for a unit, in the AIND-packaged datasets. Go to the card. + +Depth / pia→WM axis + y increases with cortical depth, so depth plots need ax.invert_yaxis(). Go to the card. + +Digital twin + A DNN trained to predict a cell's response to arbitrary stimuli (source of derived functional properties). Go to the card. + +Direct vs indirect activation + The central pitfall of optotagging: a neuron may respond to the laser because it expresses the opsin, or because a neuron that does synapses onto it. Direct responses are short-latency (<10 ms), reliable across pulses, and tightly distributed in time. Go to the card. + +Distance + Four geometric senses and two statistical ones are in routine use, and they give different answers for the same pair of points. Go to the card. + +Drift metrics + max_drift and cumulative_drift record how far, in µm, a unit's spikes moved along the probe during the session. Newer pipelines add activity_drift and drift_ptp. Go to the card. + +Drifting gratings + A full-field sinusoidal grating moving orthogonal to its own orientation. Parameters: orientation and direction (degrees), temporal frequency (Hz), spatial frequency (cycles/deg), contrast. Typically 2 s on, 1 s grey. Go to the card. Driver line - A general term for transgenic mouse lines that are engineered to label a - specific cell type or cell population by expressing a specific gene under - the control of the promoter for the cell type or cell population of interest. - A {term}`Cre line` is a common type of Driver line that allows specific - genes to be expressed when crossed with a {term}`reporter line`. - The driver line determines what cell population is targeted, and the - reporter line determines what will be expressed in that specific cell population - (for example, GFP, GCaMP, or Channelrhodopsin). + A transgenic line engineered to label a specific cell population by expressing a gene under that population's promoter. The driver line determines which cells are targeted; the reporter line determines what is expressed in them. Go to the card. + +DSI + Direction selectivity index (0–1). Go to the card. + +Dynamic foraging task + Two choices, binary reward, and reward probabilities that change during the session. A go cue opens a short window in which the mouse licks left or right; the mouse must learn from recent outcomes to track the better side. Go to the card. + +Dynamic Routing task + A context-dependent go/no-go task alternating visual and auditory blocks. The same stimulus is a target or not depending on the current block, so stimulus and meaning can be separated. Go to the card. + +Edges + Pairs of connected vertices (mesh.edges, skeleton edges). Go to the card. + +Electron microscopy (EM) + Imaging that reaches nanometer resolution to reveal tissue ultrastructure. Go to the card. + +Encoding vs decoding + Encoding asks whether an event changes neural activity; decoding asks whether the event can be read back out of the activity. Same data, opposite direction. Go to the card. + +Enhancer AAV + A virus carrying a cell-type-specific enhancer, used to restrict expression without breeding a transgenic line. Go to the card. + +Environment secrets + How the CAVE auth token is supplied when code runs on a shared or hosted machine: exported as environment variables named API_SECRET_ instead of being written to a credentials file in the home directory. Go to the card. Ephys - Shorthand for electrophysiology. + Shorthand for electrophysiology. Go to the card. + +Ephys selection bias + Spike sorting needs enough spikes to form a cluster, so sparsely active neurons are missed and large-spike, high-rate neurons — and layer 5 — are over-represented. Ophys sees many of the cells ephys does not. Go to the card. + +Epoch + A labelled stretch of time — but of what, and on whose clock, differs everywhere it appears. Go to the card. + +Error profiles + The characteristic ways automated segmentation fails, and how they differ by compartment: thin axons are dominated by split errors, thicker dendrites and somata by merges. This asymmetry is why proofreading status is tracked separately for axon and dendrite. Go to the card. + +Event detection + Deconvolving ΔF/F into discrete events, here with the L0 method. At population imaging resolutions 1- and 2-spike events are detected unreliably, particularly with GCaMP6f. Go to the card. + +Evoked vs spontaneous + Activity driven by a stimulus versus activity during the grey-screen epochs. The comparison that decides whether a response is a response at all. Go to the card. + +Excitatory V1 cell types + Pyramidal subclasses by layer/projection: 23P, 4P, 5P-IT/ET/NP, 6P-IT/CT (+ mtype clusters L2a…L6wm). Go to the card. + +Experience level + Whether the image set in a session is the one the mouse trained on (Familiar) or a different one (Novel). The axis the Visual Behavior datasets were built to test. Go to the card. Experiment - *There is no consistent use of this term* - It can refer to a stimulus protocol, an entire data collection campaign, or a single session. It is highly ambiguous. - -Fast spiking neuron -FSN -FSI - Fast spiking neurons are so called because of their "narrow," fast action - potentials, specifically as seen in intracellular recordings of a cell in - response to a prolonged step of current. Additionally, with sufficient - current injection fast spiking neurons exhibit fast spike rates, and do - not show frequency adaptation, or slowing of spike rates, over time. In - unlabeled extracellular recordings, units with narrow action potentials are - also referred to as fast spiking neurons. This feature is sometimes used - to putatively label neurons with narrow spikes as particular cell types, - such as {term}`PV+ neuron`s, among others. + There is no consistent use of this term. Establish which one is meant before joining anything. Go to the card. + +Extended + Arbor proofread to remove all merge AND split errors (correct and as-complete-as-possible). Go to the card. + +Extracellular electrophysiology + Recording voltage from outside the cell membrane, which gives better access to intact brains than intracellular recording. Its two readouts are spikes and the local field potential. Go to the card. + +Eye tracking / pupil + Ellipse fits to eye, pupil and corneal reflection per video frame, giving area, centre and rotation, plus a likely_blink flag. Recorded during physiology sessions but not during training. Go to the card. + +Faces + Triangles of connected vertex indices that tile a mesh surface (mesh.faces). Go to the card. + +Fast spiking neuron (FSN) + Narrow, fast action potentials; with enough injected current, high spike rates without frequency adaptation. In unlabelled extracellular recordings, narrow-waveform units are called fast spiking and putatively identified as PV+ cells. Go to the card. + +FIBSEM + Focused-ion-beam SEM; block-face EM that mills & images, giving near-isotropic voxels. Go to the card. + +Field of view + The imaged extent of one plane, in pixels and in µm. Recorded per experiment as field_of_view_width/height. Go to the card. + +firing_rate + Mean spike rate over the whole session. Low values may mean a sparsely active neuron or a badly detected one. Go to the card. Fluorophore - A type of molecule which absorb light and re-emit it at a longer wavelength - in a process called fluorescence. As a result, fluorophores fluoresce only - while exposed to a light source. + A molecule that absorbs light and re-emits it at a longer wavelength. Fluorophores fluoresce only while exposed to a light source. Go to the card. + +Functional connectome + A dataset linking synapse-resolution EM connectivity to recorded neural function in the same neurons. Go to the card. GABA - Gamma-aminobutyric acid (GABA) is the main inhibitory neurotransmitter in the - mammalian brain. In cortex, most GABAergic neurons are local interneurons. + The main inhibitory neurotransmitter in the mammalian brain. In cortex most GABAergic neurons are local interneurons. Go to the card. -Genetically-encoded calcium indicator -GECI - A protein expressed by a cell that will change its fluorescence upon binding - to a Ca{sup}`2+` ion. Used to visualize neural activity with fluorescence - microscopy. +Gabor patches + Spatially restricted gratings. The receptive-field mapping stimulus in Visual Coding Neuropixels: 20° diameter, three orientations on a 9 × 9 grid of screen positions, identical in every session. Go to the card. GCaMP - A family of {term}`GECI`. GCaMP was generated by a fusion of the calcium - binding domain of the calmodulin protein with green fluorescent protein (GFP). - In these data we use primarily GCaMP6f as well as some GCaMP6s, fast and slow - variants respectively. These two variants differ in their sensitivity as well - as their kinetics — primarily with regards to their decay. For more see - {cite:t}`chen2013`. + A family of GECI fusing calmodulin's calcium-binding domain to green fluorescent protein. GCaMP6f and 6s are the fast and slow variants, differing in sensitivity and especially in decay kinetics. Go to the card. -GFP - Green fluorescent protein. Discovered at FHL. +Genetically-encoded calcium indicator (GECI) +GECI + A protein expressed by a cell that changes its fluorescence on binding Ca²⁺, used to visualise neural activity with fluorescence microscopy. Go to the card. -Higher visual area +Golden Mouse (409828) + The single V1DD mouse with functional coregistration. Go to the card. + +gOSI / gDSI + Global orientation/direction selectivity indices (vector-sum variant). Go to the card. + +Graphene (graphene://) + URL protocol for dynamic, CAVE-backed (editable) segmentation/meshes, vs static precomputed://. Go to the card. + +Graphene vs Precomputed + graphene:// = dynamic/editable; precomputed:// = static. Go to the card. + +Grids / Chunk + The volume is partitioned into a 3D grid of chunks for the chunked-graph. Go to the card. + +Head fixation / head bar + A surgically implanted bar clamps the mouse's head in a repeatable position — better than 10 µm across clamp cycles, which is what makes it possible to return to the same cells on a later day. Go to the card. + +Higher visual area (HVA) HVA - A **higher visual area** is a term for cortical visual areas that receive - input from the primary visual cortex, thus considered to be "higher" in the - visual hierarchy. In primates, higher visual areas include V2, V3, V4, V5, MT, - etc. In the mouse, higher visual areas include: VISl, VIsal, VISpm, VISam, - VISrl among others. For more, see {cite:t}`glickfeld_higher-order_2017`. - -Hyperparameter - A free parameter that controls behaviors in machine learning algorithms. These - are distinct from parameters which control behaviors of the models developed by - the algorithms; hyperparameters affect how the algorithm finds the models in - the first place. + A cortical visual area receiving input from primary visual cortex, and so higher in the visual hierarchy. In the mouse: VISl, VISal, VISpm, VISam, VISrl among others. Go to the card. + +Hit / miss / false alarm / correct reject + Lick within the 750 ms window after a change = hit; no lick after a change = miss; lick after a sham change = false alarm; withholding on a sham change = correct reject. Licking before the scheduled change aborts the trial. Go to the card. + +Image set + Which eight natural images a session used (G or H, A or B). Two images are shared between sets, so novelty is a property of the other six. Go to the card. + +Imagery + The 3D grayscale (0–255) array depicting EM ultrastructure. Go to the card. + +Imaging depth + Depth in µm below the cortical surface at which a plane was collected. Roughly: <250 layer 2/3, 250–350 layer 4, 350–500 layer 5, >500 layer 6 — but layer-specific Cre lines are the reliable way to get layer specificity. Go to the card. + +Imaging plane + One two-photon focal plane. A single-plane microscope images one per session; the Multiscope/Mesoscope images up to eight. The plane, not the session, is what an ophys experiment is defined on. Go to the card. + +Indicator sparsification + Calcium indicators respond non-linearly to firing rate: bursts are boosted, isolated spikes washed out. Tuning measured with ophys therefore looks sharper and sparser than the same tuning measured with ephys. Go to the card. + +Inhibitory V1 cell types + Interneuron subclasses: BC, BPC, MC, NGC (manual) and PTC/DTC/STC/ITC (targeting-based mtypes). Go to the card. Interneuron - Also known as a local interneuron: a neuron that has short axons and synapse - exclusively with nearby neurons. In the cortex the term is often used to refer to inhibitory neurons. + A neuron with short axons that synapses only with nearby neurons. In cortex the term is often used to mean an inhibitory neuron. Go to the card. -Interspike interval +Intrinsic signal imaging (ISI) ISI - The interspike interval is the the time between two sequential action potentials (spikes) of a neuron. The ISI is used in the quality control of spike-sorting for ephys experiments, assuring that spikes assigned to a unit don't fall within the refactory period of the neuron (a few milliseconds), indicating that there is contaimination between units.. ISI is also used to characterize firing patterns of neurons. + Measuring blood-flow changes from the reflectance of red light on the brain surface. Commonly used to map retinotopy across the cortical surface and so to target later recordings. Go to the card. -Intrinsic signal imaging -ISI - Intrinsic signal imaging, also called ISI, is a method to measure changes in - blood flow associated with neural activity using reflectance of red light on - the brain's surface, measured using a standard CCD camera. The amount of red - light reflected by the brain tissue increases when oxygenated hemoglobin - perfuses the local region. The timecourse of the ISI signal is slow, and the - magnitude of the reflectance changes are small. As a result, the use of periodic - stimuli can aid in signal detection. A common use of ISI is to map - {term}`retinotopy` across the brain surface by moving a slowly drifting bar across - the visual field then measuring the signal in each pixel at the frequency of the - periodic drifting bar. ISI has also been used to identify orientation maps in - species with organized orientation maps like cats and primates, as well as to - map the location of the whisker barrels in somatosensory cortex of the mouse. - For additional papers using ISI to map the organization of the mouse visual - cortex see {cite:t}`kalatsky2003` and {cite:t}`garrett2014`. +isi_violations + Rate of inter-spike intervals shorter than the refractory period. A real neuron cannot fire that fast, so violations mean spikes from more than one cell were merged. Default threshold 0.5. Go to the card. -Local field potential +isolation_distance + Distance in Mahalanobis space to the nearest other cluster of waveforms. Higher is better separated. Go to the card. + +IT / ET / NP / CT / SP + Projection categories: intratelencephalic, extratelencephalic, near-projecting, corticothalamic, subplate. Go to the card. + +Kilosort + The template-matching sorter used for all Allen Neuropixels data. It merges automatically, so no manual curation step is needed for recordings with little drift. Go to the card. + +l_ratio + Contamination measure related to isolation distance: the probability that nearby spikes belong to this cluster. Lower is better. Go to the card. + +Layer (cortical) + L1–L6 along the pia→WM axis; drives cell-type naming. NOT the Neuroglancer layer. Go to the card. + +Level of detail (LOD) + Static meshes are smaller, multi-LOD, precomputed://; dynamic meshes are detailed, single-LOD, graphene://. Go to the card. + +Local field potential (LFP) LFP - Transient electrical potential generated in nervous tissue by the summed - activity of cells in that tissue. This is typically measured in a lower - temporal-frequency band of less than 250 Hz. +Local field potential + Transient electrical potential generated in nervous tissue by the summed activity of the cells in it, typically measured below 250 Hz. Informative about oscillations and network synchrony. Go to the card. + +Locally sparse noise + Black and white spots flashed on a grey screen, arranged so no two spots fall within 5 pixels of each other. The exclusion zone is what makes the average around any pixel structureless, so a receptive field can be recovered. Go to the card. +Manifest + The file a cache uses to know what data exists and where it was put. Instantiating a cache without naming one creates it in the working directory. There is no manifest when you read NWB directly; the file is the manifest. Go to the card. + +Martinotti cell (MC) Martinotti cell - A Martinotti cell is a particular subtype of SST cell that targets the apical - dendrites of pyramidal cells in layer 1. Martinotti cells are found in layer - 2/3 and layer 5. + A subtype of SST cell that targets the apical dendrites of pyramidal cells in layer 1. Martinotti cells are found in layer 2/3 and layer 5. Go to the card. -Minnie column - A colloquial name for the 100 micron by 100 micron square column of cortex - targeted for the census across layers. This column is a particularly well - proofread collection of cells. +Materialization & Versioning + Timestamped snapshots of the annotation DB; each version = a fixed timestamp (MICrONS v1507, V1DD v1196). Go to the card. + +Maximum / average projection + The imaging movie collapsed over time into one image — the standard way to see every cell in a plane at once. Go to the card. + +Merge errors + Two neurons' processes incorrectly joined; they add false connections. Go to the card. + +Meshes + Vertices + triangular faces defining a neuron's 3D outer surface. Go to the card. + +MeshParty / Meshwork + Python package + object bundling the L2 mesh, skeleton, and anno annotations, kept in sync. Go to the card. + +Meshpoints + Informal usage for mesh vertices. Not a formal term — say vertices, since “point” elsewhere means an annotation position. Go to the card. + +MICrONS + Cubic-millimeter functional-connectomics EM dataset of mouse visual cortex (VISp/VISal/VISrl). Go to the card. -Minnie dataset - A colloquial name for the millimeter-scale MICrONs electron microscopy dataset. +Minnie + Internal name for the MICrONS dataset/mouse (minnie65; datastack minnie65_public). Go to the card. -NWB -Neurodata Without Borders - A standardized file format for physiology and behavior data. All of our physiology and behavior data is stored in NWB files. The Visual Coding and Visual Behavior data are in NWB files with a hdf backend, while the newer data (V1DD, BCI, Dynamic Foraging, NP Ultra & Psychedelics) have a Zarr backend - which is optimized for cloud access. More info can be found [here](https://nwb.org/) +Motion correction + Registering every frame of the imaging movie to a reference before segmentation, so an ROI mask refers to the same cell throughout. Go to the card. -Neurogliaform cell - A type of interneuron that makes a diffuse axonal arbor and is thought to release {term}`GABA` through both synaptic release and volume transmission, non-selectively inhibiting neurons nearby. +mtypes + Morphology/connectivity-derived cell-type clusters (L2a…L6wm; PTC/DTC/STC/ITC). Go to the card. + +Natural movies + Black and white film clips with natural spatial and temporal statistics — usually the opening shot of Touch of Evil, chosen because it is continuous, with no cuts and varied motion. Go to the card. + +Natural scenes + Black and white photographs with natural spatial statistics, flashed for 0.25 s with no gap. Visual Coding uses 118 images drawn from the Berkeley, van Hateren and McGill image sets. Go to the card. + +Neuroglancer + WebGL browser viewer for very large volumetric connectomics data (imagery, segmentation, meshes, annotations). Go to the card. + +Neuroglancer forks + Neuroglancer is maintained as several diverging branches. Spelunker is the one CAVE datastacks link to; the Seung-lab and FlyWire branches are the other widely used ones. States are broadly compatible but not identical. Go to the card. + +Neuroglancer Layer (img/seg/ann) + The data layers in a Neuroglancer state. NOT the cortical layer. Go to the card. + +Neuroglancer State + JSON object storing all layers/view/annotations, identified by a state id. Go to the card. + +Neurogliaform cell (NGC) + An interneuron that makes a diffuse axonal arbor and is thought to release GABA through both synaptic release and volume transmission, non-selectively inhibiting nearby neurons. Go to the card. + +Neuronal process + An axon or dendrite branch of a neuron (a process that splits at branch points). Go to the card. + +Neuropil correction + An annulus around the ROI, excluding nearby cells, gives a local neuropil signal. It is subtracted from the raw trace after weighting by a per-cell r value. Go to the card. Neuropixels - A family of devices for obtaining high channel count single unit extracellular - recordings created through a collaborative open science project funded by - Howard Hughes Medical Institute, Gatsby Charitable Trust, the Wellcome Trust, - and the Allen Institute. These devices utilize modern integrated circuit - design to miniaturize aspects of electrophysiology, enabling recordings of - hundred of single units from a single probe with minimal brain damage. - {cite:t}`jun2017` describes these probes; a summary can also be found [here](background/neuropixels-description). + A family of silicon probes for high-channel-count single-unit extracellular recording, miniaturised with integrated-circuit design so that hundreds of units can be recorded from one probe with minimal brain damage. Go to the card. + +nglui (statebuilder/parser) + Python package to generate and parse Neuroglancer states from dataframes. Go to the card. + +nn_hit_rate / nn_miss_rate + Nearest-neighbour estimates of contamination and of missing spikes respectively. Go to the card. + +Nodes + Vertices in the skeleton / L2 graph. Go to the card. + +NP 1.0 / 2.0 / Ultra / Opto + 1.0: 960 sites, ~20 µm pitch, ~3.8 mm span. 2.0: 1280 sites per shank, ~15 µm pitch. Ultra: 6 µm pitch, fine detail over a shorter span. Opto: 1.0 plus 28 on-shank light emission sites. All read out 384 channels at a time. Go to the card. + +NWB (Neurodata Without Borders) + The standard file format for physiology and behaviour data. Visual Coding and Visual Behavior use an HDF5 backend; the newer datasets — V1DD, BCI, Dynamic Foraging, NP Ultra — use a Zarr backend optimised for cloud access. Go to the card. + +NWB layout + Every NWB file has the same top-level groups: general (subject, devices, electrodes or imaging planes), acquisition (signals as acquired), stimulus (what was presented), intervals (epochs, trials, blocks), processing (anything derived), units (sorted units, ephys only) and analysis (non-standard extras). What differs between datasets is what fills them — and where a dataset puts a thing is not always where you would guess, so print the tree first. Go to the card. + +Omission + 5% of non-change presentations are dropped, interrupting the expected stimulus cadence so that expectation signals can be measured. Omissions occur during recording but not during training, and never at or just before a change. Go to the card. Ophys - Shorthand for optical physiology, often in reference to {term}`Two-photon calcium imaging`, but can also include other methods such as fiber photometry. + Shorthand for optical physiology, often in reference to two-photon calcium imaging, but can also include other methods such as fiber photometry. Go to the card. + +Ophys container + The same imaging plane followed across days. Containers hold different numbers of sessions depending on which passed QC and how many retakes happened. Go to the card. + +Ophys experiment + One imaging plane in one session — the narrowest unit in the hierarchy, with its own imaging_depth and targeted_structure. Quality control passes or fails each plane separately. Go to the card. + +Ophys session + One continuous recording under the two-photon microscope. It contains one imaging plane on a single-plane scope and up to eight on the Multiscope. Go to the card. + +Opsin + A light-gated ion channel. Illumination changes its conformation, letting ions cross the membrane and either forcing the cell to spike (excitatory opsin) or suppressing spiking (inhibitory). Go to the card. Optogenetics - A method for controlling the activity of neurons by expressing light activated - ion channels (using a {term}`reporter line` ) in a specific subpopulation of - cells (using a {term}`Driver line`) to enable temporally precise control of - neural spiking. Spiking can be suppressed or enhanced using different types of - reporters. See {cite:t}`peron2011` for a review on optogenetics as a method. + Controlling neural activity by expressing light-activated ion channels in a specific subpopulation — a reporter line for the opsin, a driver line for the population — giving temporally precise control of spiking. Go to the card. Optotagging - A technique that uses {term}`optogenetics` in order to identify neurons that belong to - a specific subpopulation. See: [Optotagging](background/Optotagging). + Using optogenetics to identify which recorded units belong to a genetically defined population, by their response to laser pulses. Trains of 10 ms pulses at 20 Hz are a common stimulus. Go to the card. +Oracle score + Visual-response reliability — signal correlation across repeated “oracle” movies. Go to the card. + +OSI + Orientation selectivity index (0–1). Go to the card. + +Parvalbumin-positive (PV+) neuron Parvalbumin-positive interneuron -PV+ neuron - Fast spiking neurons, also known as fast spiking interneurons, is a - short-hand for parvalbumin positive GABA-ergic inhibitory interneurons found - in many brain regions that have strong inhibitory effects on neighboring - cells. In experimental preparations where the genetic identity of neurons - can be paired with electrophysiological recordings, PV+ neurons have short - action potentials, occasionally less than 400 µS. + Fast-spiking GABAergic interneurons with strong inhibitory effects on their neighbours; action potentials can be under 400 µs. Parvalbumin is a calcium buffer, so calcium imaging of these cells should be read cautiously. Go to the card. -Primary visual cortex -V1 -VISp - The largest visual area in cortex that receives inputs from the Lateral - geniculate nucleus of thalamus. Often referred to as V1 or VISp. +Passive replay block + The same stimuli replayed with the lick spout retracted and no reward, so task-dependent modulation can be separated from stimulus drive. Go to the card. + +Peak channel + The channel on which a unit's mean waveform is largest. A unit carries no position of its own — joining peak_channel_id to the channels table is how it acquires a CCF location, a brain-region label and a depth. Go to the card. + +Physiology + The activity side of a functional-connectomics dataset: the calcium-imaging responses recorded from the same neurons that were later reconstructed in EM. Go to the card. + +Position + The 3D coordinate of a bound spatial point (pt_position, stored in voxels by default). Go to the card. + +Precomputed format + Storage representation for arbitrarily large images/meshes/skeletons. Go to the card. + +pref_dir + Preferred direction in degrees (0–360; 0 = vertical bar moving right, CCW+). Go to the card. + +pref_ori + Preferred orientation in degrees (0–180). Go to the card. + +presence_ratio + Fraction of the session in which the unit had spikes. A low value usually means the unit drifted away from the probe. Default threshold 0.9. Go to the card. + +Probe / shank / channel / site + The recording hierarchy: a probe carries one or more shanks, a shank is patterned with recording sites, and the subset wired out for recording at any moment are the channels. Go to the card. + +Project cache + The AllenSDK entry point for the Brain Observatory datasets: it downloads what you ask for, keeps it in a known directory, and hands back manifest tables and session objects. Newer datasets have no cache — you open the NWB file yourself. Go to the card. + +Proofreading + Manual correction of split/merge errors to make neurons biologically accurate/complete. Go to the card. + +PSTH + Peri-stimulus time histogram: spikes binned relative to stimulus onset and averaged over trials, giving the time course of the response. Go to the card. + +PyChunkedGraph (PCG) / L2 graph + Hierarchical representation: L0 = voxels, L1 = supervoxels, L2 = supervoxels grouped within a chunk. Go to the card. Pyramidal cell - A type of excitatory neuron with a characteristic cell body shape and apical - dendrite. In visual cortex, pyramidal cells are by far the most common type of - excitatory neuron. + An excitatory neuron with a characteristic cell-body shape and apical dendrite. In visual cortex, by far the most common excitatory type. Go to the card. + +Q value / RPE + Latent variables of a reinforcement-learning fit to foraging behaviour: the expected value of each choice, and the reward prediction error that updates it. Useful precisely because they can then be regressed against neural activity. Go to the card. + +query_table / synapse_query + The two query entry points + filter_in_dict; note the 200k-row cap, desired_resolution, select_columns, split_positions. Go to the card. + +Radius + Half the cable thickness at a skeleton vertex (µm). Go to the card. + +readout_loc_x/y + Approximate receptive-field center in stimulus space. Go to the card. Receptive field - In a sensory context, the receptive field of a neuron is the region of the stimulus domain in which sensory stimulus needs to lie in order to evoke a response. For visual cortical cells, for example, the receptive field is the region of visual space in which stimuli can evoke neural responses. In a computational context, this notion is often generalized multiple dimensions (e.g. space, time, frequency, etc.) and thus equates to the necessary stimulus features that drive neural response (e.g. a localized grating of a specific orientation and frequency). - -Regular Spiking neuron -RS - Neurons that, when injected with a long step of current in the context of - intracellular recordings, show spike frequency adaptation where the rate of - spiking decreases over time. These neurons also have longer (or wider) action - potentials, and lower spike rates even when injected with large currents due - to hyperpolarization after each action potential. These are the most common - type of neurons in the mammalian cortex, and are often associated excitatory - neurons. In extracellular recordings, neurons with longer action potentials - are also sometimes referred to as regular spiking neurons, a feature which is - used to associate these units with specific cell types, such as excitatory - pyramidal neurons among others. - -Reporter - An exogenous coding region joined to a promoter sequence or element in an - expression vector that is introduced into cells to provide the means for - measuring the promoter activity - [source](https://www.promega.com/resources/guides/cell-biology/bioluminescent-reporters/#:~:text=What%20is%20a%20Reporter%20Gene,for%20measuring%20the%20promoter%20activity.). + The region of the stimulus domain in which a stimulus must lie to evoke a response. Generalises beyond space to any stimulus dimension, and so to the stimulus features that drive a cell. Go to the card. + +Reference table + A table linked to another (usually nucleus_detection_v0) by shared annotation id, adding _ref columns. Go to the card. + +Regular spiking neuron (RS) + Longer action potentials and spike-frequency adaptation — the rate falls over a sustained current step. The most common cortical type, usually associated with excitatory pyramidal neurons. Go to the card. Reporter line - A reporter line is a transgenic mouse line that is engineered to - express a specific protein that enables monitoring or manipulation of neural - activity (such as GFP, GCaMP, or Channelrhodopsin) under the control of cre or - FLP recombinase, or a tetracycline transactivator system. The gene engineered - into the reporter line will not be expressed unless the protein that controls - reporter gene expression (such as cre or FLP) is present, such as by breeding - a mouse from the reporter line with a mouse from a specific {term}`Driver - line` that expresses the control protein. Injecting a virus that delivers cre - or FLP in a cell type specific manner can also trigger the expression of the - reporter gene. + A transgenic line engineered to express a protein that monitors or manipulates activity — GFP, GCaMP, channelrhodopsin — but only once the controlling protein (Cre or FLP) is present. Go to the card. + +Residual / Separation score + The two coregistration-quality metrics. Go to the card. + +Resolution + Physical voxel size in nm/voxel (MICrONS 4×4×40; V1DD 9×9×45); set per query via desired_resolution. Go to the card. + +Response modulation index (RMI) + The normalised contrast between visual and auditory target response rates, collapsing two hit rates into one number that says which context the mouse is behaving in. Go to the card. + +Retake + A second attempt at a session_type after the first failed QC. Why prior_exposures_to_image_set and not session_type tells you whether a session was truly the first with novel images. Go to the card. Retinotopy retinotopic map - retinotopy refers to the mapping of visual space on to neural space. - Most visual areas of the brain contain an orderly map of visual space such that - neighboring regions in space are represented by neighboring regions in the brain. - Retinotopic maps are typically measured in terms of altitude (aka vertical retinotopy), - referring to the axis from upper to lower visual field, and and azimuth - (aka horizontal retinotopy), referring to the axis from left to right in space. + The mapping of visual space onto neural space: neighbouring points in the visual field are represented by neighbouring points in the brain. Measured as altitude (upper–lower) and azimuth (left–right). Go to the card. +ROI mask ROI - A region of interest is a general term that describes a subregion of an image. - When used in reference to two photon calcium imaging, an ROI is the mask containing pixels thought to belong to a single neuron. + The pixel mask for one segmented cell in an imaging plane. In two-photon data an ROI is the set of pixels thought to belong to a single neuron. Go to the card. + +Root_id (pt_root_id) + Unique integer for a specific segmentation = a specific version of a cell (a.k.a. segment / object id). Go to the card. + +Running speed + Speed on the running disc, temporally aligned to the activity traces. Same length as ΔF/F, so a stimulus epoch indexes into both. Go to the card. Saccade - A rapid and ballistic eye movement that shifts the visual field between two fixation points. Mice are not foveal animals, and their eye movements are different from foveal animals (such as humans). + A rapid ballistic eye movement between fixation points. Mice are not foveal animals and their eye movements differ from those of foveal species. Go to the card. + +Scan + The scan_idx from functional imaging; part of the ROI's unique id. Go to the card. + +Segmentation + A 3D array where each voxel stores the root_id of the object at that location. Go to the card. + +Segments (= root/object id) + “Segment id” used as a synonym for root id — collides with the skeleton sense of “segment”. Go to the card. + +Segments (skeleton) + An unbranched run of vertices between branch/end points. Go to the card. + +Serial-section EM + Many ultrathin sections are cut from a block, imaged one by one, then re-aligned into a volume. Resolution is fine in x/y and coarse in z, so voxels are strongly anisotropic. Go to the card. Session - A physiological and/or behavioral recording that happens at one time. + The databook defines it as “a physiological and/or behavioral recording that happens at one time”, but four narrower senses are in use as identifiers. Go to the card. + +Share link / middleauth + Authenticated state-sharing mechanism. Go to the card. + +Signal vs noise correlation + Signal correlation compares two cells' mean responses across stimulus conditions — do they like the same things. Noise correlation compares their trial-to-trial fluctuations to the same condition — do they vary together. Go to the card. -Skeleton - A linear tree-like structure that defines the shape of a neuron. +Single unit vs multi-unit + Not two categories but a gradient, from complete and uncontaminated to incomplete and highly contaminated. Every analysis still has to draw a binary line somewhere; quality metrics are how you draw it deliberately. Go to the card. +Skeletons + Tree-like linear representation of a neuron's branching (vertices + edges, radius, compartments). Go to the card. + +snr + Waveform amplitude relative to background noise on the peak channel. Go to the card. + +Somatostatin (SST) cell Somatostatin cell - A type of inhibitory interneuron expressing the molecular marker somatostatin (SST, or - sometimes SOM). SST cells tend to target the distal dendrites of excitatory - neurons, and have important roles in regulating the activity of excitatory - neurons. + An inhibitory interneuron expressing somatostatin (SST, sometimes SOM). SST cells tend to target the distal dendrites of excitatory neurons, and have important roles in regulating their activity. Go to the card. + +Source + Disambiguation: image_source/segmentation_source, the Neuroglancer layer source, and skeleton path_between(source,…). Go to the card. + +Source (presynaptic) + The presynaptic partner of a synapse (pre_pt_root_id). Go to the card. Spatial frequency - How often sinusoidal components of as signal or structure repeat per unit of distance. - When used in reference to drifting gratings, spatial frequency means the distance between the - bars of the grating. Typically measured as cycles per degree. + How often the sinusoidal components of a signal repeat per unit distance — for a grating, the spacing of its bars. Typically cycles per degree. Go to the card. + +Spike band / LFP band + The two streams split off each channel: the spike band at 30 kHz with a 500 Hz high-pass, carrying action potentials from adjacent neurons; the LFP band at 2.5 kHz, carrying low-frequency fluctuations from a wider area. Go to the card. + +Spike raster + One row per trial, one tick per spike, aligned on an event. The plot to make before any model, because it shows trial-to-trial structure that an average hides. Go to the card. + +Spike sorting + Assigning detected spikes to individual neurons — a blind source separation problem. Detection, extraction, feature extraction, clustering, then validation against the refractory period. Go to the card. + +Split errors + A process incorrectly appears to stop; they remove true connections. Go to the card. + +Spontaneous activity + An epoch of mean-luminance grey with no patterned stimulus, included in most sessions as a baseline for visually evoked activity. Go to the card. + +standard_transform + Package converting voxel/nm coordinates to pia-flattened micron coordinates (minnie_ds, v1dd_ds). Go to the card. + +State + Four unrelated meanings, two of which appear in the same workshop. Go to the card. + +Static gratings + A stationary full-field sinusoidal grating flashed for 0.25 s. No temporal frequency; phase becomes a parameter instead. Go to the card. + +Status flags + Booleans status_axon/status_dendrite recording whether each arbor was proofread, plus valid_id (root id at assessment). Go to the card. + +Stimulus epoch table + When each interleaved stimulus block began and ended. In Visual Coding 2P the bounds are given as imaging frames, so they index directly into the ΔF/F and running-speed traces. Go to the card. + +Stimulus presentations table + One row per stimulus shown, with its parameters and its start_time and stop_time. The table every alignment starts from. In NWB it lives under stimulus/presentation, or as a TimeIntervals table under intervals — which one depends on the dataset. Go to the card. + +Stimulus template + The literal image shown, stored alongside the stimulus table for image and movie stimuli. Often available both unwarped and warped — the warped version is what the monitor rendered. Go to the card. + +Strategy values + dendrite_clean, dendrite_extended, axon_partially_extended, axon_fully_extended, axon_interareal (MICrONS only), none. Go to the card. + +Structure acronym + The CCF region label attached to a channel or unit — VISp, MOs, LSr. A unit with no CCF registration gets coordinates of [-1, -1, -1]. Go to the card. + +Supervoxel (pt_supervoxel_id) + L1 grouping of voxels within a chunk; the stable internal id an annotation binds to. Go to the card. + +Surround suppression + A stimulus extending beyond a cell's classical receptive field suppresses its response. Stronger in superficial layers, and one of the questions V1DD's windowed and full-field gratings were designed to address. Go to the card. + +SWC format + Standard skeleton file format (one of three: SWC, meshwork-h5, precomputed). Go to the card. + +Synapse size + Synapse size in voxels; correlates with surface area / strength. Go to the card. + +synapse_target_predictions_ssa + Per-synapse postsynaptic-compartment prediction (soma / spine / shaft). Go to the card. + +synapses_pni_2 / synapses_v1dd + The sole synapse tables (337M / 639M rows). Go to the card. -Targeted structure - The brain region where data was collected from. +Table Viewer + Dash app to query/filter one table and select rows in Neuroglancer. Go to the card. + +Tables + CAVE annotation tables (synapses, nuclei, cell types, proofreading, coregistration). Go to the card. + +Tags / Shortcuts + Keyboard-driven annotation labels for fast bulk labeling in Neuroglancer. Go to the card. + +Target + Disambiguation: target_id (reference link) vs synaptic postsynaptic partner vs path target_index. Go to the card. + +Target (postsynaptic) + The postsynaptic partner of a synapse (post_pt_root_id). Go to the card. + +TEASAR + Algorithm that turns the L2 graph into a skeleton tree. Go to the card. + +TEM + Transmission EM; MICrONS/V1DD are serial-section TEM-style (thin sections, anisotropic z). Go to the card. Temporal frequency - How many complete periods the signal goes through for a given unit of time. - Typically measured in Hertz. + How many complete periods the signal goes through per unit time. Typically Hz. Go to the card. + +Three-photon (3P) imaging + Raises signal-to-noise for deep imaging of densely labelled tissue. Used to extend the V1DD centre column to white matter, where 2P image quality has degraded. Go to the card. + +Token / auth + Google-account credential required before any programmatic access, saved per server. Go to the card. Transgenic line - A mouse line whose genome has been altered by the introduction of one or more - foreign DNA sequences. For these contexts, this typical involves using - {term}`Cre line`s to drive the expression of a {term}`Reporter line` within a - specific subset of cells. + A mouse line whose genome has been altered by introducing foreign DNA. Here, typically a Cre line driving expression of a reporter line within a specific subset of cells. Go to the card. + +Trials table + One row per trial: timing landmarks and outcome flags. Usually nwb.intervals['trials'], but not always — the BCI dataset keeps its trials under stimulus/presentation, because there the lickport is driven by the neuron. And a “trial” is not always behavioural: in the cell-type look-up table it is a laser pulse train. Go to the card. + +Tuning curve + Mean response plotted against a stimulus parameter. The shape of the curve is what selectivity indices such as OSI and DSI summarise in one number. Go to the card. Two-photon calcium imaging - A term for techniques which measure neural activity of neurons by measuring a - fluorescent calcium indicator. These indicators are usually a protein - expressed in a cell, such as {term}`GCaMP`, often using a specific combination - of {term}`Driver line` and {term}`reporter line`s to express GCaMP in a - specific subset of neurons. Fluorescent dyes can also be used to perform - calcium imaging. At rest a neuron has low levels of calcium, and when the - neuron spikes calcium flows into the neuron and raises the level of calcium, - which binds to the calcium indicator and increases the emitted fluorescence in - a specific wavelength. See {cite:t}`svoboda2006` for a review of two-photon - calcium imaging. + Measuring neural activity through a fluorescent calcium indicator such as GCaMP. At rest a neuron has low calcium; when it spikes, calcium flows in, binds the indicator and raises the emitted fluorescence. Go to the card. + +Two-photon excitation + Two long-wavelength photons excite one fluorophore. Absorption is non-linear in photon density, so only a single voxel is excited at a time — that is what gives optical sectioning in intact tissue. Go to the card. + +Types of errors in imagery + Section/alignment artifacts (folds, cracks, missing sections) that propagate into segmentation. Go to the card. + +Ultrastructure + Fine sub-cellular EM features: organelles, mitochondria, synapses, myelin. Go to the card. Unit - A putative neuron in extracellular electrophysiology, with varying degrees of - confidence assigned to it. In extracellular electrophysiology, neurons are - referred to as *units*, because we cannot guarantee that all the spikes - assigned to one unit actually originate from a single cell. Unlike in - two-photon imaging, where you can visualize each neuron throughout the entire - experiment, with electrophysiology we can only “see” a neuron when it fires a - spike. If a neuron moves relative to the probe, or if it’s far away from the - probe, some of its spikes may get mixed together with those from other - neurons. Because of this inherent ambiguity, quality metrics allow you to find - the right units for your analysis. Even highly contaminated units can contain - potentially valuable information about brain states, but certain types of - analysis require more stringent quality thresholds to ensure that all of the - included units are well isolated from their neighbors. + Two different recording modalities use this word for their basic recorded element, and they are not the same thing. Go to the card. + +Unit quality metrics + Per-unit numbers describing how badly spike sorting may have gone wrong for that unit — contamination from other neurons, spikes missed, or the unit drifting away. None is perfect; which thresholds apply depends on the analysis. Go to the card. + +Units table + One row per sorted unit: spike times, mean waveform, quality metrics, and the peak channel that gives it a location. The primary table of any ephys dataset. Go to the card. + +Unproofread + An arbor that has not been comprehensively corrected. It is truncated by split errors and may carry merged fragments of other cells, so its apparent partners are unreliable. Go to the card. + +V1DD (V1 Deep-Dive) + Functional (2p/3p calcium) + EM dataset of V1 across all layers in 4 mice (~50k neurons/mouse). Go to the card. + +V1DD functional index + V1DD's Golden-Mouse column/volume/plane/roi scheme, distinct from MICrONS session/scan/unit. Go to the card. + +valid_roi + The ophys equivalent of a unit quality flag: whether cell classification judged a segmented ROI to be a real cell. Only valid ROIs are released. Go to the card. + +Vertex / Vertices + Points in 3D (N×3, nanometers) that, connected, build meshes and skeletons. Go to the card. VIP cell - A type of inhibitory interneuron expressing the molecular marker Vasoactive Intestinal Protein. VIP cells tend to target {term}`Somatostatin cell`s rather than excitatory neurons. This role as a "disinhibitory specialist" is thought to be important for context-dependent modulation of cortical activity. Many VIP cells have a characteristic bipolar axon that points along the axis of the cortical column and are thus often called "bipolar cells". + An inhibitory interneuron expressing Vasoactive Intestinal Protein. VIP cells tend to target somatostatin cells rather than excitatory neurons; this role as a “disinhibitory specialist” is thought to matter for context-dependent modulation of cortical activity. Go to the card. + +VISp / VISal / VISrl +Primary visual cortex +V1 +VISp + The visual cortical areas (V1 / AL / RL / LM) the volume spans and assigns. Go to the card. + +Volume + A cubic-mm 3D EM image dataset spanning a cortical region. Go to the card. + +VORTEX + NIH program (Virtual Observatory of the Cortex) funding continued proofreading; source of the vortex_* tables. Go to the card. + +Voxel + The smallest 3D image unit; anisotropic 4×4×40 nm (MICrONS) / 9×9×45 nm (V1DD). Go to the card. + +Watertight + EM meshes are NOT watertight, so Trimesh .volume/.center_mass are invalid. Go to the card. Waveform -Spike - In a system neuroscience setting, this often refers to the voltage over time - measured with an electrode when an individual neuron produces an action - potential. + The voltage over time measured at an electrode when a neuron fires an action potential. The per-unit mean waveform is what the shape metrics are computed from. Go to the card. + +ΔF/F (dF/F) + Change in fluorescence normalised by a baseline. The baseline is the median fluorescence in a 180 s window centred on each time point, so ΔF/F is a relative, unitless signal. Go to the card. +::::: +:::::: + +:::{note} +This page is generated from [`855c456`](https://github.com/AllenInstitute/allen-connectomics-glossary/commit/855c456f480bac600d71aa14bdfad1043cccd558) of the +[Allen Glossary](https://github.com/AllenInstitute/allen-connectomics-glossary) repository. +Do not edit it directly — edits are overwritten the next time it is regenerated. +To fix a definition or add a term, open a pull request against that repository. ::: diff --git a/scripts/build-glossary-page.mjs b/scripts/build-glossary-page.mjs new file mode 100644 index 00000000..a38ebd62 --- /dev/null +++ b/scripts/build-glossary-page.mjs @@ -0,0 +1,809 @@ +// build-glossary-page.mjs — render the Allen Glossary into databook/glossary.md. +// +// node scripts/build-glossary-page.mjs \ +// --source /path/to/allen-connectomics-glossary \ +// --out databook/glossary.md +// +// The glossary lives in its own repository and is the source of truth for the +// definitions. This script only reads it — never writes to it — and turns its +// data/ directory into one MyST page for the databook: cards, the category +// pills that double as filters, the legends, and a search box. +// +// The output is a single Markdown file, so nothing else in the databook has to +// change: it overwrites databook/glossary.md in place and the existing +// `- file: glossary` entry in _toc.yml keeps working. +// +// Three choices worth knowing about: +// +// * The cards are rendered here, not in the browser. The page is complete +// HTML before any JavaScript runs, so it prints, survives JS being off and +// does not flash empty on load. The script only hides and shows what is +// already in the DOM. +// +// * Output is deterministic: same data in, byte-identical file out. There is +// no generated-at timestamp unless you pass --stamp, so the sync workflow +// only opens a PR when the glossary itself actually changed. +// +// * The renderer lives here rather than in the glossary repository, so the +// databook owns how it presents the data and the glossary stays a pure +// source. The cost is that upstream changes land here unannounced, so the +// script sorts them by how bad they are: something that would produce a +// wrong page — a term in a category that does not exist — stops the build +// with the offending term id, while something that merely costs a +// cross-reference its link — a stale entry in the alias map — warns and +// carries on. A hand-maintained file will rot, and one dead alias must not +// be able to freeze every future glossary update. --strict makes the +// survivable cases fatal too, for checking the alias map deliberately. + +import fs from "node:fs"; +import path from "node:path"; +import vm from "node:vm"; +import { execFileSync } from "node:child_process"; + +/* ── arguments ───────────────────────────────────────────────── */ + +const argv = process.argv.slice(2); +const flag = name => { + const i = argv.indexOf(name); + return i === -1 ? null : argv[i + 1]; +}; + +const USAGE = "usage: node scripts/build-glossary-page.mjs --source --out [--repo ] [--commit ] [--aliases ] [--preview ] [--stamp]"; + +const SOURCE = flag("--source"); +const OUT = flag("--out"); +if (!SOURCE || !OUT) { + console.error(USAGE); + process.exit(2); +} + +const ROOT = path.resolve(SOURCE); +if (!fs.existsSync(path.join(ROOT, "data", "terms.js"))) { + console.error(`error: ${ROOT} does not look like an allen-connectomics-glossary checkout (no data/terms.js).`); + process.exit(2); +} + +const STAMP = argv.includes("--stamp"); +const STRICT = argv.includes("--strict"); + +// Warnings need to reach a person. On a runner that means an annotation, which +// shows on the run summary and against the pull request the sync opens. +const IN_ACTIONS = process.env.GITHUB_ACTIONS === "true"; +const warn = msg => console.warn(`${IN_ACTIONS ? "::warning::" : "warning: "}${msg}`); + +// Where the glossary lives, as owner/name. Everything the page links back to is +// derived from this, so a fork building its own copy points at its own glossary +// rather than at the canonical one. +const REPO = (flag("--repo") || "AllenInstitute/allen-connectomics-glossary").replace(/^\/+|\/+$/g, ""); +if (!/^[\w.-]+\/[\w.-]+$/.test(REPO)) { + console.error(`error: --repo must look like owner/name, got "${REPO}"`); + process.exit(2); +} +const [REPO_OWNER, REPO_NAME] = REPO.split("/"); +const REPO_URL = `https://github.com/${REPO}`; +// GitHub Pages serves a project site from the lower-cased owner +const SITE_URL = `https://${REPO_OWNER.toLowerCase()}.github.io/${REPO_NAME}/`; + +// Alias map, read from beside the output page unless told otherwise. Optional: +// without it the page still builds, just with fewer cross-references resolving. +const ALIAS_PATH = flag("--aliases") || + path.join(path.dirname(path.resolve(OUT)), "glossary-aliases.json"); + +const COMMIT = flag("--commit") || (() => { + try { + return execFileSync("git", ["-C", ROOT, "rev-parse", "HEAD"], { encoding: "utf8" }).trim(); + } catch { + return null; // not a checkout, or no git — provenance line degrades to the repo link + } +})(); + +/* ── load the glossary's data/ ───────────────────────────────── */ + +// The data files are plain JSON wrapped in `window.X =` so the site works over +// file://. Run them against a stand-in window rather than parsing them, so this +// script never disagrees with what the browser would load. +function loadData() { + const sandbox = { window: {} }; + vm.createContext(sandbox); + for (const f of ["config.js", "terms.js", "diagrams.js"]) { + const src = fs.readFileSync(path.join(ROOT, "data", f), "utf8"); + vm.runInContext(src, sandbox, { filename: f }); + } + return sandbox.window; +} + +const W = loadData(); +const SITE = W.SITE; +const CATS = W.CATEGORIES; +const CAT = Object.fromEntries(CATS.map(c => [c.id, c])); +const DISCIPLINES = W.DISCIPLINES || []; +const DS = W.DATASETS; +const ANATOMY = W.ANATOMY; +const TERMS = W.TERMS; +const DIAG = W.DIAGRAMS || {}; + +/* ── helpers ─────────────────────────────────────────────────── */ + +const esc = s => String(s).replace(/[&<>"]/g, c => ({ "&": "&", "<": "<", ">": ">", '"': """ }[c])); +const strip = s => String(s).replace(/<[^>]+>/g, ""); +// definitions are authored with entities (&, <) — undo them for the +// search haystack so a query for "&" or "<" behaves the way a reader expects +const unent = s => String(s).replace(/</g, "<").replace(/>/g, ">") + .replace(/"/g, '"').replace(/'/g, "'").replace(/&/g, "&"); + +const byName = (a, b) => a.term.toLowerCase().localeCompare(b.term.toLowerCase()); + +/* ── card ────────────────────────────────────────────────────── */ + +// The search haystack rides on the element, so filtering never has to touch the +// source data — the page carries everything it needs. +function haystack(t) { + return [ + t.term, + unent(strip(t.def)), + CAT[t.category] ? CAT[t.category].label : t.category, + (t.datasets || []).map(d => (DS[d] ? DS[d].label : d)).join(" "), + ].join(" ").toLowerCase(); +} + +function cardHTML(t) { + const c = CAT[t.category]; + if (!c) throw new Error(`term "${t.id}" has unknown category "${t.category}"`); + const svg = t.diagram ? DIAG[t.diagram] : null; + + const chips = []; + if (t.datasets && t.datasets.length === 1) { + const d = DS[t.datasets[0]]; + chips.push(`${esc(d ? d.label : t.datasets[0])} only`); + } + if ((t.flags || []).includes("ambiguous")) { + chips.push(`⚠ ambiguous`); + } + if ((t.flags || []).includes("context")) { + chips.push(`adjacent method`); + } + for (const [k, url] of Object.entries(t.ng || {})) { + if (!url) continue; + chips.push(`${esc(DS[k] ? DS[k].label : k)} ↗`); + } + // A term's source chip cites where the definition came from. Most of them + // cite the databook — which is where this page now lives, so citing it as an + // external source is circular. Three cases: + // + // * the databook's own glossary: that is this page. Dropped. + // * another databook page: kept, but as an internal link that stays in the + // book rather than bouncing the reader to the published copy of it. + // * anywhere else: left alone. + const src = t.source && t.source.url ? String(t.source.url) : null; + if (src) { + const inBook = src.match(/^https?:\/\/allenswdb\.github\.io\/(.*)$/i); + if (!inBook) { + chips.push(`${esc(t.source.label)} ↗`); + } else { + const rel = inBook[1].replace(/^\/+/, ""); + // glossary.html, or the site root, is this page + if (rel && !/^glossary\.html(#.*)?$/i.test(rel)) { + chips.push(`in this book`); + } + } + } + + return [ + `
`, + svg ? `
${svg}
` : "", + `
${esc(c.short)}
`, + `

${esc(t.term)}

`, + `

${t.def}

`, + chips.length ? `
${chips.join("")}
` : "", + `
`, + ].filter(Boolean).join("\n "); +} + +/* ── legends ─────────────────────────────────────────────────── */ + +// Pills are grouped by discipline. With connectomics and physiology terms in one +// glossary, the discipline is the first cut a reader makes, and grouping the +// pills gets that for free without adding a second control. +function pillsHTML() { + const groups = [ + ...DISCIPLINES.map(d => ({ id: d.id, label: d.label })), + { id: "both", label: "Both" }, + ]; + const seen = new Set(); + const blocks = groups.map(g => { + const items = CATS.filter(c => c.discipline === g.id); + items.forEach(c => seen.add(c.id)); + if (!items.length) return ""; + return `
+ ${esc(g.label)} + ${items.map(pill).join("\n ")} +
`; + }); + // anything whose discipline is missing or unrecognised still gets a pill + const rest = CATS.filter(c => !seen.has(c.id)); + if (rest.length) { + blocks.push(`
+ Other + ${rest.map(pill).join("\n ")} +
`); + } + return blocks.filter(Boolean).join("\n "); +} + +function pill(c) { + const n = TERMS.filter(t => t.category === c.id).length; + return ``; +} + +function anatomyHTML() { + return ANATOMY.map(a => + `${esc(a.label)}`).join("\n "); +} + +/* ── term index ──────────────────────────────────────────────── */ + +// The cards live in a `{raw} html` block, and Sphinx neither indexes raw HTML +// for its own search nor registers cross-reference targets in it. So the same +// terms are emitted a second time as a real MyST `{glossary}` directive, folded +// as a plain list. That buys two things the cards cannot: +// +// * `{term}`Neuroglancer`` from anywhere else in the databook resolves again +// (matching is case-insensitive), instead of warning and rendering as +// plain text under `jb build -n`; +// * the databook's own search box finds glossary terms. +// +// Matching is on the term name exactly as written in data/terms.js. Names that +// differ from what the databook writes — "basket cell" here vs "Basket cell +// (BC)" upstream — will not resolve, and deliberately are not guessed at: a +// derived alias that strips "(BC)" also turns "d_prime (unit)" into "unit" and +// silently points a cross-reference at the wrong definition. Aliases belong in +// data/terms.js as an explicit field. +const plain = s => unent(strip(String(s))).replace(/\s+/g, " ").trim(); + +// The databook and the glossary do not always spell a term the same way, so an +// entry can carry extra names. A glossary directive accepts several term lines +// above one definition, and each becomes its own cross-reference target. +// +// Everything here is validated rather than trusted: an id that no longer exists +// upstream, or an alias that shadows a real term name, fails the build. A wrong +// alias is worse than a missing one — it silently sends a reader to the wrong +// definition — so nothing is guessed at from the term text. +function loadAliases() { + if (!fs.existsSync(ALIAS_PATH)) { + console.warn(`note: no alias map at ${ALIAS_PATH}; cross-references rely on exact name matches`); + return new Map(); + } + + const raw = JSON.parse(fs.readFileSync(ALIAS_PATH, "utf8")); + const byId = new Map(TERMS.map(t => [t.id, t])); + const names = new Set(TERMS.map(t => String(t.term).trim().toLowerCase())); + + const out = new Map(); // term id -> [alias, ...] + const unknown = [], shadowed = []; + + for (const [alias, id] of Object.entries(raw.aliases || {})) { + const a = alias.trim(); + if (!byId.has(id)) { unknown.push(`${a} -> ${id}`); continue; } + // an alias equal to a real term name would define that term twice, which + // Sphinx reports as a duplicate description + if (names.has(a.toLowerCase())) { shadowed.push(a); continue; } + if (!out.has(id)) out.set(id, []); + out.get(id).push(a); + } + + // A stale entry is skipped, not fatal. This file is maintained by hand and + // the glossary moves on its own schedule, so entries will rot; making that + // stop the build would mean one dead alias freezes every future glossary + // update, which is far worse than a handful of references losing their link. + // Both cases below degrade to exactly what no alias at all would give. + // + // Pass --strict to turn them back into errors when checking the file itself. + const notes = []; + if (unknown.length) { + notes.push(`${unknown.length} alias(es) point at a term the glossary no longer has ` + + `(renamed or removed upstream): ${unknown.join(", ")}. Those references will not link.`); + } + if (shadowed.length) { + notes.push(`${shadowed.length} alias(es) are now redundant — the glossary defines that ` + + `name itself: ${shadowed.join(", ")}. Safe to delete from ${path.basename(ALIAS_PATH)}.`); + } + for (const n of notes) warn(n); + if (notes.length && STRICT) { + throw new Error(`${ALIAS_PATH}: stale entries, and --strict was given.`); + } + + const n = [...out.values()].reduce((s, a) => s + a.length, 0); + console.log(`aliases: ${n} extra name(s) across ${out.size} term(s)` + + (notes.length ? `, ${unknown.length + shadowed.length} stale` : "")); + return out; +} + +function termIndex() { + const aliases = loadAliases(); + const seen = new Map(); + const dupes = []; + const entries = []; + + for (const t of [...TERMS].sort(byName)) { + const name = String(t.term).trim(); + const key = name.toLowerCase(); + if (seen.has(key)) { dupes.push(name); continue; } // a repeated term name would fail the build + seen.set(key, t.id); + // the definition is one paragraph, so a stray newline cannot break out of + // the indented block the glossary directive expects + const def = plain(t.def) || "See the card above."; + const lines = [name, ...(aliases.get(t.id) || [])].join("\n"); + entries.push(`${lines}\n ${def} Go to the card.`); + } + + if (dupes.length) { + warn(`${dupes.length} duplicate term name(s) left out of the index: ${dupes.join(", ")}`); + } + + return { count: entries.length, body: entries.join("\n\n") }; +} + +/* ── page ────────────────────────────────────────────────────── */ + +const CSS = ` +/* Allen Glossary — generated, do not edit here. Every rule is scoped to + .acg-root so nothing leaks into the rest of the databook, and every class is + prefixed acg- so the theme's own .card/.grid/.chip rules cannot reach in. */ +.acg-root{ + --acg-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; + --acg-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace; + --card:#ffffff; --ink:#12161c; --muted:#55606d; --faint:#8b95a1; + --line:#e0e5ea; --line-2:#cfd6de; --panel:#eef1f4; + --accent:#0d7d88; --accent-ink:#0a5a63; + --accent-soft:color-mix(in srgb, var(--accent) 10%, transparent); + --scaffold:#7c8695; --neuron:#39424f; --dendrite:#3f6fa8; --axon:#b07a2b; --synapse:#c04a6e; + --error:#c0392b; --ok:#2a8f57; + --surface:var(--card); --surface-2:var(--panel); + --border:var(--line); --border-strong:var(--line-2); + --r:8px; + --shadow:0 1px 2px rgba(20,24,29,.05), 0 6px 18px -12px rgba(20,24,29,.25); + font-family:var(--acg-sans); color:var(--ink); +} +/* The databook theme stamps data-theme on ; honour it in both directions + and fall back to the OS preference when it is left on auto. */ +@media (prefers-color-scheme: dark){ + html:not([data-theme="light"]) .acg-root{ + --card:#141a21; --ink:#e7edf3; --muted:#97a1af; --faint:#67707e; + --line:#232b35; --line-2:#303a46; --panel:#1a2129; + --accent:#3cced9; --accent-ink:#86e4ec; + --accent-soft:color-mix(in srgb, var(--accent) 14%, transparent); + --scaffold:#8f99a8; --neuron:#c2cad6; --dendrite:#71a4dd; --axon:#d7a355; --synapse:#e2809c; + --shadow:0 1px 2px rgba(0,0,0,.4), 0 8px 22px -14px rgba(0,0,0,.8); + } +} +html[data-theme="dark"] .acg-root{ + --card:#141a21; --ink:#e7edf3; --muted:#97a1af; --faint:#67707e; + --line:#232b35; --line-2:#303a46; --panel:#1a2129; + --accent:#3cced9; --accent-ink:#86e4ec; + --accent-soft:color-mix(in srgb, var(--accent) 14%, transparent); + --scaffold:#8f99a8; --neuron:#c2cad6; --dendrite:#71a4dd; --axon:#d7a355; --synapse:#e2809c; + --shadow:0 1px 2px rgba(0,0,0,.4), 0 8px 22px -14px rgba(0,0,0,.8); +} +html[data-theme="light"] .acg-root{ + --card:#ffffff; --ink:#12161c; --muted:#55606d; --faint:#8b95a1; + --line:#e0e5ea; --line-2:#cfd6de; --panel:#eef1f4; + --accent:#0d7d88; --accent-ink:#0a5a63; + --scaffold:#7c8695; --neuron:#39424f; --dendrite:#3f6fa8; --axon:#b07a2b; --synapse:#c04a6e; +} + +.acg-root *{box-sizing:border-box} +.acg-root [hidden]{display:none !important} +.acg-root .mono{font-family:var(--acg-mono)} + +/* ── control bar ──────────────────────────────────────────────── */ +.acg-bar{display:flex; align-items:center; gap:.6rem; flex-wrap:wrap; margin:0 0 .9rem} +.acg-search{flex:1 1 260px; display:flex; align-items:center; gap:.45rem; min-width:0; + background:var(--card); border:1px solid var(--line-2); border-radius:99px; padding:.3rem .8rem} +.acg-search:focus-within{border-color:var(--accent); box-shadow:0 0 0 3px var(--accent-soft)} +.acg-search svg{width:15px; height:15px; flex:none; color:var(--faint)} +.acg-search input{flex:1; min-width:0; font:inherit; font-size:.85rem; color:var(--ink); + background:none; border:0; outline:none; padding:0} +.acg-search input::-webkit-search-cancel-button{cursor:pointer} +.acg-count{font-family:var(--acg-mono); font-size:.68rem; color:var(--faint); + white-space:nowrap; font-variant-numeric:tabular-nums} + +/* ── legends ──────────────────────────────────────────────────── */ +.acg-legends{display:flex; flex-direction:column; gap:.5rem; margin:0 0 1.1rem} +.acg-legend{font-size:.75rem; min-width:0} +.acg-legend > summary{cursor:pointer; color:var(--muted); font-family:var(--acg-mono); + font-size:.63rem; letter-spacing:.1em; text-transform:uppercase; list-style:none} +.acg-legend > summary::-webkit-details-marker{display:none} +.acg-legend > summary::before{content:"\\25B8 "; color:var(--faint)} +.acg-legend[open] > summary::before{content:"\\25BE "} +.acg-legend .acg-hint{font-family:var(--acg-sans); text-transform:none; letter-spacing:0; + font-size:.72rem; color:var(--faint)} +.acg-body{display:flex; flex-wrap:wrap; gap:.35rem; padding:.55rem 0 0 .9rem; align-items:center} +.acg-body.acg-anat{gap:.2rem .9rem} +.acg-body.acg-anat span{display:inline-flex; align-items:center; gap:.35rem; + color:var(--muted); font-size:.72rem} +.acg-body.acg-anat i{width:9px; height:9px; border-radius:99px; flex:none} +.acg-caveat{margin:.55rem 0 0 .9rem; font-size:.72rem; line-height:1.45; color:var(--faint); max-width:70ch} + +.acg-pillgroup{display:flex; flex-wrap:wrap; align-items:center; gap:.3rem; width:100%} +.acg-glabel{font-family:var(--acg-mono); font-size:.58rem; letter-spacing:.1em; + text-transform:uppercase; color:var(--faint); width:6.2rem; flex:none} +@media (max-width:640px){ .acg-glabel{width:100%} } + +/* the category legend doubles as the filter — clicking a pill narrows the grid */ +.acg-pill{appearance:none; font:inherit; font-size:.72rem; cursor:pointer; color:var(--muted); + background:var(--card); border:1px solid var(--line); border-radius:99px; + padding:.16rem .6rem .16rem .45rem; display:inline-flex; align-items:center; gap:.35rem; + line-height:1.35} +.acg-pill i{width:9px; height:9px; border-radius:2px; flex:none; background:var(--cc)} +.acg-pill:hover{border-color:var(--line-2); color:var(--ink)} +.acg-pill[aria-pressed="true"]{border-color:var(--cc); color:var(--ink); + background:color-mix(in srgb, var(--cc) 12%, transparent); font-weight:600} +.acg-pill .acg-n{font-family:var(--acg-mono); font-size:.6rem; color:var(--faint); + font-variant-numeric:tabular-nums} +.acg-pill.acg-zero{opacity:.4} +.acg-clear{appearance:none; font:inherit; font-size:.68rem; cursor:pointer; background:none; + border:0; color:var(--accent-ink); text-decoration:underline; padding:.16rem .3rem} + +/* ── the grid ─────────────────────────────────────────────────── */ +/* A grid, not columns: entries read left to right along each row, the order + people expect from an alphabetical list. */ +.acg-grid{display:grid; grid-template-columns:repeat(auto-fill, minmax(250px, 1fr)); gap:12px} + +.acg-card{display:flex; flex-direction:column; margin:0; + background:var(--card); border:1px solid var(--line); border-left:3px solid var(--line-2); + border-radius:var(--r); padding:.55rem .65rem .6rem; box-shadow:var(--shadow)} +.acg-card .acg-art{background:var(--panel); border:1px solid var(--line); border-radius:5px; + padding:3px 4px; margin-bottom:.4rem} +.acg-card .acg-art svg{display:block; width:100%; height:auto; color:var(--neuron)} +.acg-card .acg-eb{margin-top:auto; font-family:var(--acg-mono); font-size:.56rem; font-weight:700; + letter-spacing:.09em; margin-bottom:1px} +.acg-card .acg-h{margin:0; padding:0; border:0; font-size:.92rem; font-weight:700; + line-height:1.2; letter-spacing:-.012em; color:var(--ink)} +.acg-card .acg-name{color:inherit; text-decoration:none} +.acg-card .acg-name::after{content:"#"; color:var(--faint); font-weight:400; margin-left:.3em; + opacity:0; font-family:var(--acg-mono); font-size:.8em} +.acg-card:hover .acg-name::after,.acg-card .acg-name:focus-visible::after{opacity:1} +.acg-card:target{outline:2px solid var(--accent); outline-offset:3px} +.acg-card .acg-def{margin:.22rem 0 0; font-size:.79rem; color:var(--muted); line-height:1.38} +.acg-card .acg-def code{font-family:var(--acg-mono); font-size:.88em; background:var(--panel); + color:var(--ink); padding:.05em .3em; border-radius:4px; word-break:break-word; border:0} +.acg-card .acg-meta{display:flex; flex-wrap:wrap; gap:.25rem; margin-top:.42rem} + +.acg-chip{display:inline-flex; align-items:center; gap:.25rem; font-family:var(--acg-mono); + font-size:.57rem; letter-spacing:.05em; text-transform:uppercase; line-height:1.6; + border:1px solid var(--line-2); color:var(--muted); border-radius:99px; padding:.06rem .42rem} +.acg-chip.acg-ds{border-style:dashed} +.acg-chip.acg-warn{border-color:currentColor; color:var(--axon)} +.acg-chip.acg-ng{border-color:var(--accent); color:var(--accent-ink); text-decoration:none} +.acg-chip.acg-ng:hover{background:var(--accent-soft)} +.acg-chip.acg-aside{border-style:dotted; color:var(--faint)} +.acg-chip.acg-src{border-style:dotted; color:var(--faint); text-decoration:none} +.acg-chip.acg-src:hover{color:var(--accent-ink); border-color:var(--accent)} + +.acg-root mark{background:var(--accent-soft); color:inherit; border-radius:2px; padding:0 .1em} +.acg-empty{text-align:center; color:var(--faint); padding:2.5rem 0; font-size:.85rem} +.acg-foot{margin-top:1.6rem; padding-top:.7rem; border-top:1px solid var(--line); + font-size:.72rem; line-height:1.5; color:var(--faint)} +.acg-foot a{color:var(--accent-ink)} + +/* The term index is a MyST {glossary} directive, so it renders outside + .acg-root as the theme's own
, inside a sphinx-design dropdown. Both are + styled by stylesheets the deployed site already carries — jupyter-book ships + sphinx-design's CSS on every page regardless of whether a page uses it, and + the pinned toolchain guarantees the same bundle. Compacted here, since this + + +
+ +
+ + ${TERMS.length} terms +
+ +
+
+ Category — the colour on a card's edge. Click to filter. +
+ ${pillsHTML()} + +
+
+
+ Illustration — colour inside a drawing means anatomy, never category +
+ ${anatomyHTML()} +
+

The illustrations are generated rather than hand-drawn. They are being + checked by the people who know the data, but errors cannot be ruled out at this stage — + read them as sketches of the idea, and trust the definition over the picture. + ${withArt} of ${TERMS.length} terms have one.

+
+
+ +
+ ${sorted.map(cardHTML).join("\n ")} +
+ + + +

+ Generated from the Allen Glossary + (revision ${esc(SITE.revision)}), which is the source of truth for these definitions — + corrections and new terms belong there, not on this page.${refs ? `
Further reading: ${refs}` : ""} +

+ +
+ +`; +} + +/* ── the databook page ───────────────────────────────────────── */ + +// One MyST file. The body is a single `{raw} html` block fenced with five +// colons — the databook enables colon_fence, and colons let the embedded script +// use backticks freely, which a ``` fence would not. +function page() { + const provenance = COMMIT + ? `[\`${COMMIT.slice(0, 7)}\`](${REPO_URL}/commit/${COMMIT})` + : "the source repository"; + + const idx = termIndex(); + + return `\ + + +# Glossary + +${TERMS.length} terms across ${CATS.length} categories, from the +[Allen Glossary](${SITE_URL}). Search matches names, definitions, categories and dataset +names; the category legend doubles as a filter, so clicking one or more pills narrows the +list. Every term has a permalink you can paste into an email — click a term name to copy +the link to it. + +:::::{raw} html +${bodyHTML()} +::::: + +## Term index + +The same ${idx.count} terms as a plain list, A to Z. This is what the databook's own +search box and any \`{term}\` cross-reference elsewhere in the book resolve against, +so it is folded away rather than left out. + +::::::{dropdown} Every term, A to Z +:::::{glossary} +${idx.body} +::::: +:::::: + +:::{note} +This page is generated from ${provenance} of the +[Allen Glossary](${REPO_URL}) repository. +Do not edit it directly — edits are overwritten the next time it is regenerated. +To fix a definition or add a term, open a pull request against that repository. +::: +`; +} + +/* ── standalone preview ──────────────────────────────────────── */ + +// The same body in a bare page, for checking the result without standing up a +// Jupyter Book build. The theme switch mimics how the databook stamps +// data-theme on , so dark mode can be checked too. +function previewHTML() { + return ` + + + +Glossary — databook preview + + +

Glossary

+

Standalone preview of the generated databook page — the databook's own +chrome (sidebar, header) is not shown. Toggle the theme to check both palettes.

+${bodyHTML()} + +`; +} + +/* ── write ───────────────────────────────────────────────────── */ + +const out = path.resolve(OUT); +const text = page(); +const before = fs.existsSync(out) ? fs.readFileSync(out, "utf8") : null; + +fs.mkdirSync(path.dirname(out), { recursive: true }); +fs.writeFileSync(out, text); + +const PREVIEW = flag("--preview"); +if (PREVIEW) { + const p = path.resolve(PREVIEW); + fs.mkdirSync(path.dirname(p), { recursive: true }); + fs.writeFileSync(p, previewHTML()); + console.log(`${path.relative(process.cwd(), p) || p} (preview)`); +} + +const rel = path.relative(process.cwd(), out) || out; +const changed = before !== text; +console.log( + `${rel} ${(text.length / 1024).toFixed(0)} kB ` + + `${TERMS.length} terms, ${CATS.length} categories ` + + `[${changed ? (before === null ? "created" : "updated") : "unchanged"}]` +);