edfcore 0.5.42 → 0.5.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -109,5 +109,5 @@ export declare const SIGNAL_FIELD_BLOCK_OFFSETS: {
109
109
  readonly reserved: 224;
110
110
  };
111
111
  /** Published package version. Kept in sync with package.json by a test. */
112
- export declare const VERSION = "0.5.42";
112
+ export declare const VERSION = "0.5.44";
113
113
  //# sourceMappingURL=constants.d.ts.map
package/dist/constants.js CHANGED
@@ -79,5 +79,5 @@ export const SIGNAL_FIELD_BLOCK_OFFSETS = {
79
79
  reserved: 224,
80
80
  };
81
81
  /** Published package version. Kept in sync with package.json by a test. */
82
- export const VERSION = '0.5.42';
82
+ export const VERSION = '0.5.44';
83
83
  //# sourceMappingURL=constants.js.map
package/docs/CHANGELOG.md CHANGED
@@ -6,6 +6,51 @@ alone does not tell you whether you were affected.
6
6
  edfcore is pre-1.0. Patch releases have carried behaviour changes where the old behaviour was a
7
7
  defect; those are called out below.
8
8
 
9
+ ## 0.5.44
10
+
11
+ - **Added** reading one recording from several places at once. Everything in the suite reads
12
+ sequentially, and nothing in the API documents an ordering requirement — a recording is a plain
13
+ struct, `readWindow` takes it and returns a value, and the obvious thing to write in a viewer is
14
+ `Promise.all` over the channels or the visible range. That was untested territory: the reads share
15
+ a source, an index whose `onsetTicks` memoises, and a timeline every rebasing path consults.
16
+ - Correctness holds. Five overlapping windows resolved together give what the same five give one at
17
+ a time, and so does the whole API at once — a window, a record range, the annotations, an index
18
+ build and a full validation sweep, launched together and compared against the same five in order.
19
+ It also holds over a source that resolves reads in **reverse order of arrival**, which is the case
20
+ worth having: a network returns what it returns when it returns it, and a reader that assumed its
21
+ own issue order would come apart exactly there.
22
+ - Then the one place concurrency costs something, which is worth naming because it is invisible.
23
+ `record-index.ts` says `onsetTicks(r)` "reads that ONE record and memoises the answer", and
24
+ `locate-cost.test.ts` checks that a second call is free. It memoises on **resolution** rather than
25
+ on request, so ten calls for the same record launched together issue ten reads. The eleventh,
26
+ after they settle, issues none.
27
+ - That is a cost rather than a defect, and the package already documents the remedy: `cachedSource`
28
+ exists so that "concurrent reads wanting the same block issue ONE underlying read". Wrapped in it,
29
+ the same ten calls issue none at all — the block was already resident from the open, which is the
30
+ observation `large-files.md` makes about the reads that come with opening a file not being wasted.
31
+ The answer is identical either way.
32
+
33
+ ## 0.5.43
34
+
35
+ - **Added** the two halves of what a sample width decides, written side by side. EDF stores each
36
+ sample in two bytes and BDF in three; that is the whole difference between the families as far as
37
+ the data records go, and `decodeDigital` keeps it where it belongs. The suite tested each width
38
+ against expected values and never one against the other.
39
+ - For a value both widths can hold, the two files disagree about everything except the number: the
40
+ record is half again as long, the declared digital range is 256 times wider, `bitValue` differs by
41
+ the same factor — and the decoded samples are bit-identical. That is "the width is an encoding",
42
+ asserted where it could fail.
43
+ - For a value only BDF can hold, the EDF file does not hold it. Two bytes cannot carry −300,000, so
44
+ what is written is the low sixteen bits and what comes back is those bits sign-extended: 27,680.
45
+ edfcore reports it with no diagnostic and no `outOfDigitalRangeCount`, which is correct and worth
46
+ writing down — the file is well formed, 27,680 is inside its declared range, and the loss happened
47
+ before edfcore saw a byte. Nothing in an EDF header can record that a writer had a number it could
48
+ not store.
49
+ - The whole low-bits sequence is asserted rather than the first value, and the same waveform in the
50
+ two families is shown to be two different recordings carrying identical diagnostics — which is the
51
+ point. `out-of-range.test.ts` covers the other case, a sample outside the DECLARED range in a
52
+ width that can hold it; this is the case where the width itself is the limit.
53
+
9
54
  ## 0.5.42
10
55
 
11
56
  - **Added** the transformation that changes what the samples MEAN without changing the samples.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "edfcore",
3
- "version": "0.5.42",
3
+ "version": "0.5.44",
4
4
  "description": "Modern, typed, zero-dependency reader for EDF, EDF+, BDF and BDF+ biosignal files. Works in browsers and Node with true random access.",
5
5
  "keywords": [
6
6
  "edf",
package/src/constants.ts CHANGED
@@ -93,4 +93,4 @@ export const SIGNAL_FIELD_BLOCK_OFFSETS = {
93
93
  } as const;
94
94
 
95
95
  /** Published package version. Kept in sync with package.json by a test. */
96
- export const VERSION = '0.5.42';
96
+ export const VERSION = '0.5.44';