Repository navigation
parseSEG 0.10.1: the SEG-D writer counts samples as the reader does - #4
Merged
Merged
Conversation
- segd/writer: `declaredSamples` follows the reader's rule. A Rev 2 trace whose Trace Header Extension #1 gives 0 samples is sized by its channel set's window, as the reader sizes it (with a warning); the writer took the 0 and refused such a trace, so a file the reader reads could not be written back. A negative window is no count (the reader stops there), not a negative one. Rev 3 was already the reader's rule. Test: tsegdreader extension_sample_count_of_zero writes the file it reads back strictly and gets the same samples (refused before the fix). - keys, convert/tosegd: GH#1 times through `generalHeaderUtc(g1)` (the same 1950-2049 reading, NaN for a year outside 0-99), without the century worked out at each call; `common/years` is no longer imported there. - docs/design/vendor_maps.md: the implementation notes said NIF went through the toolchain's nifbuilder/nifreader on a --path in config.nims. Maps are read by vendor/maps' own tokenizer and the scaffold is written with common/niftext; nothing comes from the toolchain. - tests/tdocs: the examples are compiled without the toolchain's dist/nimony path, which src/ no longer uses. nim test, testRelease, testV3, asan and docs pass (58 test files). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-ups to 0.10.0. No API change.
segd/writer.nim): the sample count a trace's headers declare now follows the reader's rule. A Rev 2 trace whose Trace Header Extension parseSEG 0.8.0: keysAt, failed-row reads, chunk window origin, SEG-Y from TraceKeys #1 gives 0 samples is sized by its channel set's window, as the reader sizes it. The writer used to take the 0 and refuse the trace, so a file the reader reads could not be written back. A negative window counts as no count. Rev 3 already followed the reader. New check intests/tsegdreader.nim(extension_sample_count_of_zero): such a file writes back strictly with the same samples.model/keys.nimandconvert/tosegd.nimcallgeneralHeaderUtc(g1), which reads the year the same way (1950-2049).docs/design/vendor_maps.mdno longer says NIF goes through the toolchain's NIF library (maps have their own tokenizer, the scaffold usescommon/niftext).tests/tdocs.nimstops adding the toolchain'sdist/nimonypath.Local:
nim test,testRelease,testV3,asananddocspass (58 test files).🤖 Generated with Claude Code