-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #130 from pastas/hpd_extension
Add hydropandas extension
- Loading branch information
Showing
7 changed files
with
450 additions
and
7 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# ruff: noqa: D104 F401 | ||
from pastastore.extensions.accessor import ( | ||
register_pastastore_accessor as register_pastastore_accessor, | ||
) | ||
|
||
|
||
def activate_hydropandas_extension(): | ||
"""Register Plotly extension for pastas.Model class for interactive plotting.""" | ||
from pastastore.extensions.hpd import HydroPandasExtension as _ | ||
|
||
print( | ||
"Registered HydroPandas extension in PastaStore class, " | ||
"e.g. `pstore.hpd.download_bro()`." | ||
) |
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,15 @@ | ||
# ruff: noqa: D100 | ||
from pastas.extensions.accessor import _register_accessor | ||
|
||
|
||
def register_pastastore_accessor(name: str): | ||
"""Register an extension in the PastaStore class. | ||
Parameters | ||
---------- | ||
name : str | ||
name of the extension to register | ||
""" | ||
from pastastore.store import PastaStore | ||
|
||
return _register_accessor(name, PastaStore) |
Oops, something went wrong.