-
Notifications
You must be signed in to change notification settings - Fork 9
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
Partial preprocessor implementation #52
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
5c97716
refactor naming and CLI api to new preprocessor
5288da4
change entry point name
d868e0b
changes to names of hooks, working on testing:
d3b0e40
minor renames, tests with explicit yamls
ed41b32
working preprocessor
353539e
add python api and tests
6400d81
convert all tests to use temp directories and files, except BMI tests.
d7193d5
switch timestep extraction order so no initialization of jobs if bad …
5df8600
documentation for changes made with preprocessor and the renaming models
c27a0e3
cleanup
1ca1cde
rename test file
70bda53
switch tests to use raises
9e522d2
add python api Preprocessor to top level imports
aef535f
update docs, cleanup, add another tests
6016668
add py high level api docs
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
import sys | ||
import os | ||
sys.path.append(os.path.realpath(os.getcwd() + "/../../../../")) | ||
# sys.path.append(os.path.realpath(os.getcwd() + "/../../../../")) | ||
|
||
import matplotlib.pyplot as plt | ||
|
||
import pyDeltaRCM | ||
|
||
|
||
delta = pyDeltaRCM.pyDeltaRCM() | ||
delta = pyDeltaRCM.DeltaModel() | ||
|
||
for _t in range(0, 1): | ||
for _t in range(0, 2): | ||
delta.update() | ||
|
||
delta.finalize() | ||
|
||
|
||
fig, ax = plt.subplots() | ||
ax.imshow(delta.bed_elevation, vmax=-4.5) | ||
ax.imshow(delta.bed_elevation, vmax=-4) | ||
plt.show() |
This file was deleted.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.. api.model: | ||
|
||
***** | ||
model | ||
***** | ||
|
||
This is the main model code. | ||
|
||
This class is defined in ``pyDeltaRCM.model``. | ||
|
||
|
||
.. currentmodule:: pyDeltaRCM.model | ||
|
||
.. autosummary:: | ||
:toctree: ../../_autosummary | ||
|
||
DeltaModel | ||
|
||
|
||
|
||
Model configuration reference | ||
============================= | ||
|
||
.. toctree:: | ||
:maxdepth: 1 | ||
|
||
yaml_defaults |
File renamed without changes.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
.. api.preprocessor: | ||
|
||
********************************* | ||
Preprocessor | ||
********************************* | ||
|
||
The high-level API is principally defined in ``pyDeltaRCM.preprocessor``. | ||
|
||
|
||
.. currentmodule:: pyDeltaRCM.preprocessor | ||
|
||
.. autosummary:: | ||
:toctree: ../../_autosummary | ||
|
||
PreprocessorCLI | ||
Preprocessor | ||
preprocessor_wrapper | ||
BasePreprocessor |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
from .deltaRCM_tools import Tools | ||
from .deltaRCM_driver import pyDeltaRCM | ||
from .model import DeltaModel | ||
from .preprocessor import Preprocessor | ||
from .bmi_delta import BmiDelta | ||
from .shared_tools import _get_version | ||
|
||
__all__ = ['Tools', 'pyDeltaRCM', 'BmiDelta'] | ||
__all__ = ['DeltaModel', 'Preprocessor', 'BmiDelta'] | ||
__version__ = _get_version() |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
from pyDeltaRCM import command_line | ||
from . import preprocessor | ||
|
||
if __name__ == '__main__': | ||
command_line.run_model() | ||
preprocessor.preprocessor_wrapper() |
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
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -142,6 +142,3 @@ coeff_U_ero_sand: | |
alpha: | ||
type: ['float', 'int'] | ||
default: 0.1 | ||
timesteps: | ||
type: ['float', 'int'] | ||
default: 10 | ||
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
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.
How come we remove the notion of a default timestepping?