-
Notifications
You must be signed in to change notification settings - Fork 18
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
Separate model view from view settings for more reliable reload #99
Merged
Merged
Changes from 14 commits
Commits
Show all changes
32 commits
Select commit
Hold shift + click to select a range
e42ecd9
rough draft of only restoring view settings, not model settings - thi…
kkiesling a253599
remove commented lines and functions that are no longer needed
kkiesling 0c6d89f
remove unnecessary import
kkiesling 7ce9e4b
remove missed print statement
kkiesling 5ee873b
more streamlined to use composition over inheritance
kkiesling 1b187f7
trying to asses view equality and populating ids
kkiesling 748baf8
trying to separate just the view parameters from the rest of view ind…
kkiesling b130f62
separate out only the _PlotBase parameters and check those
kkiesling 95ef00e
only store necessary info for reload in pickle file
kkiesling 4d371be
cleaned up docstrings
kkiesling e9e92a0
make view params attribute on plotview to simplify
kkiesling 3e996c9
remove debugging print statements
kkiesling eb34f8b
need to copy view params from previous view
kkiesling ac39180
updated docstrings for new classes
kkiesling 0ff3ed4
Apply suggestions from code review
kkiesling ed014f5
issue warning and ignore plot settings if load fails
kkiesling 81b41bb
typo
kkiesling 8051d2f
remove mistaken imports
kkiesling 3ab3f4b
ids_map and prop_map don't need to be private
kkiesling 7e3ecd3
wording changes
kkiesling ca2eab5
need to add view_params to list of attributes
kkiesling 6ad6cde
increment plotmodel version
kkiesling 08a9a38
simplify try/except statement
kkiesling 635fbf9
use_settings_pkl in docstring
kkiesling 9990c72
store full currentView so that view_ind and view_params are both saved
kkiesling 6a5f909
list of attribures as class attribute
kkiesling 05743d8
restore domain properties if file hashes are unchanged as well
kkiesling 56e12dd
prop_map and properties attributes were redundant
kkiesling 90bf435
adopt_plotbase must be in PlotView to be able to set params
kkiesling 8825405
make cell_ids, instances, and mat_ids properties
kkiesling ebe5460
make initial view the currentview and always create a default view
kkiesling 9ae7a76
compare active and current views before updating current view to chec…
kkiesling File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any reason we can't just save the entire
currentView
? As is, this misses other information. For example, if you change cell/material color assignments, close the plotter, and re-open, those assignments are gone.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The goal of this was to prevent having to store the large arrays with the cell/mat/property data to the pickle file smaller. Plus the goal of this PR was to separate the model-dependent properties from model-independent properties. Though I can see how this property is in the gray zone. If the material/cells IDs change, then the mapping of colors to materials/is no longer valid. I will play with it and see what can be done. Might have to go back to using hashes in that if the hashes are unchanged, the entire current view can be reused, but if the hashes differ, then use only the independent view settings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, and I am just remembering that we stored the full
model
in the past which is where that large amount of excess data came from. So storing the full currentView should be no issue.