Extra columns from separate file via "--extracols" flag #87
+41
−6
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.
For a long time, particle quantities computed outside splash have been read through a "hack" where they are disguised as "divv" columns. These changes aim for a proper implementation and here is a summary:
dump_01234
, an extra quantity, e.g.etot
, can be written to a separate unformatted file of the formdump_01234.etot.extras
.--extracols
flag, e.g.,splash dump_01234 --extracols=etot
. For more than one extra quantity, stored in separate .extra files, a comma-separated list can be provided to--extracols
. The corresponding environment variable isSPLASH_EXTRACOLS
.etot
, in splash.Other than being a proper implementation, compared to the "divv hack", this implementation allows arbitrarily many extra columns to be read (instead of just four), and properly labels the extra columns and so the user doesn't forget what quantities were calculated in a ".divv file". With these changes, we could also probably get rid of code that is specific for reading divv and curlv data.