-
Notifications
You must be signed in to change notification settings - Fork 68
Re-allow restart in driven solver by parsing csv table from file #393
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
phdum-a
wants to merge
16
commits into
main
Choose a base branch
from
phdum/fix_restart_printing
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
- Add DrivenSolverIndex data container to group values - Restart acts on total sample (freq and excitation combined) - Add EnumerateView helper for C++17 compatibility - Add tests
- Don't allow empty_cell_val per column for consistent re-parsing - Fix lshift bug in Column - Remove unused drive_source_index in PostOperator CSV - Remove unused AppendHeader, Append Row in TableWithCSVFile - Add comments - Add small tweaks for measurement table parsing Propagate table column block index - Needed for row alignment check during table reload
- Assumes all entries are all double
- Add function to return csv filepath for potential error messages
- Replace pointer to common options with explicit passing, in order to not write custom move
- Must validate table structure against expectation - Must copy some parameter from reference that can't be parsed - Validate cursor location with restart - Properly set nr_expected_measurement_rows for all solvers
- Thread through objects needed for init and print in call
- Move fem_op_t so PostOperatorCSV ctor can use it
- Move expected filling pattern into free function for testing - Add test case csv files to load
In PostOperatorCSV: - m_idx_row -> row_i - m_idx_value -> row_idx_v - excitation_idx_all -> ex_idx_v_all - SingleColBlock() -> HasSingleExIdx() - may_reload_table() -> MayReloadTable Also some test names changed.
17083ed
to
bb9f14d
Compare
b20b718
to
0c9f142
Compare
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.
This resolves #376.
Palace had the "Restart" flag in the driven solver. Previously this was simple because printing always appended to files row-by-row. A started run did not need to know what happened or what was written before the restart.
With then new_postpro changes (#302) and multi-excitation support (#309), this is more complicated since all data for the full run is stored by PostOperatorCSV. This is all due to the fact that multi-excitations can't just append to rows below but need to change columns to the side. To re-enable restart, we have to parse back the csv file from disk, which we do using scnlib. When we load from the csv, we have to compare to the expected table, in order to (a) validate that the read in tables are in a good state (b) recover information about the Table state (like internal column names) not in the csv.
Additionally, we clean up various parts of the code for simplicity and to make it more testable. We add several unit tests for the table reload.
The commits have been squashed and cleaned to be understandable one-by-one.