Definition, Uses, and Scope
A polysomnography (PSG) annotated dataset organizes synchronized physiological signals from sleep studies, examination context, and one or more time-aligned layers of human or algorithmic annotation. It can support sleep physiology research, scorer education, algorithm development, quality control, and reproducible methods. A typical resource is structured around whole-night recordings or continuous segments and links one or more types of annotation—such as sleep stages, arousals, respiratory events, limb movements, cardiac events, or technical artifacts—to the corresponding timeline.
Such a dataset is not merely a hypnogram, nor does its presence imply that every record has a complete montage, all event types, or clinical diagnostic suitability. An annotation is an interpretation produced under a particular protocol, rule set, signal-quality condition, and scorer judgment; it is not context-free absolute truth. Public access, zero price, or large scale does not automatically establish representative sampling, reliable labels, or a license suitable for commercial use. Data contents, provenance, version, permission, and the intended task must all be checked before use.
Signals, Labels, and Temporal Structure
PSG may include electroencephalography, electrooculography, chin electromyography, electrocardiography, airflow, thoracic and abdominal effort, oxygen saturation, body position, snoring, and limb electromyography, but the actual channels vary by era, laboratory, device, and examination purpose. Each channel also has a sampling rate, physical unit, gain, reference, filter, sensor type, and interval of validity. Channels carrying the same broad name may not be directly comparable when placement or processing differs, and a missing channel must not be silently represented as normal signal or an ordinary zero value.
Annotations may assign wake, non-rapid-eye-movement, and rapid-eye-movement stages to fixed epochs, while onset and duration intervals may describe arousals, apneas, hypopneas, desaturations, periodic limb movements, position changes, and artifacts. Documentation should state whether events may overlap, how boundaries are set, how unscored time differs from absence of an event, and which events and denominators generate summary indices. Automated predictions, a technologist's initial score, expert review, and consensus labels should occupy distinct fields so that labels with different origins are not flattened into one layer.
Scoring Rules, Versions, and Annotation Provenance
Sleep-stage and event scoring depend on an identified rule system and version. Historical collections may use earlier staging conventions, while newer projects may use different editions of a professional scoring manual. Stage combinations, hypopnea thresholds, desaturation or arousal associations, and movement-event rules can therefore differ. When legacy stages are mapped to a newer vocabulary or event definitions are harmonized, the original labels, conversion rule, and non-convertible cases should be retained. Semantic differences must not be erased merely to produce tidy classes.
Provenance should include the scoring protocol, software version, display settings, channels visible to the scorer, scorer qualifications, initial and review workflow, blinding status, and edit history. Where several scorers participate, their separate labels should be retained when possible, or at least agreement measures and the conflict-resolution procedure should be supplied. A consensus label also needs a documented formation process. Annotation versions must be bound to the signal files, data dictionary, and dataset release so that users can distinguish physiological variation from rule changes or later corrections.
File Formats, Documentation, and Cross-dataset Harmonization
A resource may use EDF or EDF+ for waveforms and annotations and may pair them with XML, CSV, JSON, text, or proprietary files. A shared file extension does not ensure common channel names, event vocabularies, temporal precision, character encoding, or missing-value conventions. Complete documentation should include a data dictionary, protocol, channel table, sampling and calibration details, file-pairing rules, relationships among participant and night identifiers, time-zone handling, quality flags, checksums, a change log, and a list of known issues.
Cross-dataset work should begin with concept mapping rather than file concatenation. Units, channel aliases, references, stage codes, event hierarchies, age groups, and examination settings must be harmonized or explicitly distinguished, with resampling, filtering, cropping, and label transformations recorded. In a whole-night record, lights out, bedtime, sleep onset, recording start, and the valid analysis interval are not interchangeable. An incorrect time origin or boundary rule can shift all labels relative to their signals and contaminate an analysis even when superficial summary checks appear normal.
Signal Quality, Label Uncertainty, and Bias
Quality assessment must examine both signals and labels. Common problems include electrode detachment, saturation, baseline drift, motion artifact, sensor replacement, unsynchronized clocks, long missing intervals, duplicate files, and truncated records. A dataset should provide channel- or interval-level quality indicators and explain which nights were excluded, repaired, or rescored. The fact that a file opens, has the expected number of epochs, or contains a summary index does not prove that its waveform is adequate for reliable identification of the target phenomenon.
Human scoring includes borderline cases and inter-scorer variation, while algorithmic pre-annotation can introduce model bias into the reference labels. Studies should report label origin and the proportion of uncertain or unscored data, using multiple scorers, adjudication, probabilistic labels, or sensitivity analysis where appropriate. Data from one laboratory, a disease-specific clinic, one device family, or a narrow age range may reflect referral patterns, first-night effects, treatment status, and collection era. A large record count cannot supply absent populations or remove selection bias.
Machine-learning Splits, Evaluation, and Reproducibility
For machine learning, training, validation, and test sets should be divided by participant rather than by randomly sampled epochs. Repeated nights from one person, neighboring segments, re-exported copies, or derived features from the same source record can leak information across sets and inflate performance. Preprocessing parameters, normalization statistics, class resampling, and decision thresholds must likewise be fitted using training data only. The test set should remain independent, and external validation should, when feasible, include other centers, devices, or populations.
Evaluation must fit the task. In addition to overall accuracy, reports may include class-specific results, confusion patterns, event sensitivity and precision, temporal overlap, calibration, failure cases, and uncertainty intervals. Agreement with human scoring does not by itself demonstrate benefit for clinical outcomes, and metrics based on different labeling systems are not directly comparable. A reproducibility record should identify the data release, inclusion manifest, code and dependencies, random seeds, preprocessing, exclusion rules, and hardware-sensitive settings. Repeated tuning against the test set creates hidden overfitting and should be prevented.
Privacy, Access Governance, and Clinical Limits
PSG resources may contain identifying dates, age, rare conditions, device identifiers, free text, audio or video, and distinctive physiological patterns; removing names does not guarantee that linkage is impossible. Publishers should apply de-identification, data minimization, and risk assessment consistent with consent and applicable rules, choosing open, application-based, or controlled-compute access according to sensitivity. Users must follow data-use agreements, prohibitions on re-identification and out-of-scope sharing, protect downloaded copies, access tokens, and derived files, and perform required handling when authorization expires or a withdrawal applies.
Governance should also cover release freezing, issue notification, corrections, withdrawn records, citation, and long-term preservation. Suitability for research or algorithm evaluation does not automatically make a resulting model an authorized clinical tool. Diagnosis, severity assessment, or treatment selection for an individual still requires a complete clinical context, qualified review, and applicable clinical and regulatory processes. A mature PSG annotated dataset lets users trace the evidence chain for every label while clearly identifying populations, events, and uses that fall outside its evidentiary scope.