Skip to content

JSON Input and Output#361

Closed
daleroberts wants to merge 45 commits into
masterfrom
dr-347
Closed

JSON Input and Output#361
daleroberts wants to merge 45 commits into
masterfrom
dr-347

Conversation

@daleroberts

Copy link
Copy Markdown
Member

Adds JSON Lines (JSONL) input and output support for DynAdjust data.

It uses the JSONL format which is a variation on JSON that uses one object per line, so it is streamable, diffable, and easier to process with standard tools than XML.

Key points:

  • Adds JSONL import support to dnaimport.
  • Adds --output-json to dnaadjust to emit JSONL report sidecars.
  • Provides resources/xml2jsonl.py for converting existing DynaML XML files to JSONL.
  • Supports stations, scalar measurements, direction sets, GNSS baselines, GNSS point clusters, covariance arrays, reference-frame metadata, ignore flags, and observation epochs.
  • Ensures adjustment JSONL output uses the same measurement grammar accepted by the JSONL parser, including grouped direction sets and GNSS clusters.
  • Adds parser and printer tests covering JSONL import, output validity, and round-trip-sensitive cases.

How To Use

Import JSONL directly with dnaimport:

  dnaimport -n gnss_jsonl sampleData/gnss-networkstn.jsonl sampleData/gnss-networkmsr.jsonl -r GDA2020 --flag-unused-stations

Convert existing DynaML XML to JSONL:

  resources/xml2jsonl.py stations.xml measurements.xml

or write to a specific file:

  resources/xml2jsonl.py stations.xml measurements.xml -o network.jsonl

Enable JSONL output from adjustment runs with --output-json:

  dnaadjust -n <network-name> --output-json

This keeps the existing text reports and also writes JSONL siblings, for example:

  <network>.adj.jsonl
  <network>.xyz.jsonl
  <network>.apu.jsonl   # when positional uncertainty output is enabled
  <network>.cor.jsonl   # when station correction output is enabled
  <network>.m2s.jsonl   # when measurement-to-station output is enabled

daleroberts and others added 30 commits March 11, 2026 09:56
Remove DynaML.xsd, including unit tests
Initial changes to support SIRGAS 95 and 2000
Report adjustment durations in HH:MM:SS for durations greater than 60s
Add support for epoch of observation #325
- Matrix class: packed/symmetric storage, attach-to-mmap, calloc allocator
- LM solver + Anderson acceleration CLI
- Static build fixes (glibc 2.34+ pthread)
- Matrix test suite
Memory and performance improvements
@daleroberts daleroberts marked this pull request as draft May 22, 2026 02:47
@daleroberts daleroberts deleted the dr-347 branch May 22, 2026 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants