Coder Social home page Coder Social logo

openearth / xbeach-toolbox Goto Github PK

View Code? Open in Web Editor NEW
13.0 11.0 6.0 3.93 MB

Collection of Python modules for pre- and postprocessing XBeach models and output files

Home Page: https://xbeach-toolbox.readthedocs.io/en/latest/

License: GNU General Public License v3.0

Python 100.00%
coastal modelling morphology numerical sediment-transport storm-surge waves xbeach

xbeach-toolbox's Introduction

ReadTheDocs pytest-py310 pylint pypi-upload

About the xbeach-toolbox

Welcome to the xbeach-toolbox!

This package contains a set of general tools to setup and postprocess 1D and 2D XBeach models.

The tools have been written in Python, please see the sections below for further instructions.

Information about this package and its contents can also be viewed on:

https://xbeach-toolbox.readthedocs.io/en/latest/

Information about the use of the XBeach model itself can be found on:

https://xbeach.readthedocs.io/en/latest/.

Getting started / installation

Pip packages are hosted on the pypi server and can be installed using:

pip install xbTools.

Release notes

Release notes
0.0.1 first testing of package on test.pypi
0.0.n additional testing on test.pypi until release
1.0.0 first official release on pypi ๐ŸŽ‰

Usage / examples

Basic examples have been added to the examples folder in the project.

For both a 1D and 2D simulation these python notebooks show how the tools can be used to setup a model.

Contributing

fork, issue, branch, commit, review, approve, merge

Contact

Menno de Ridder - [email protected]

Cas van Bemmelen - [email protected]

Marlies van der Lugt - [email protected]

xbeach-toolbox's People

Contributors

casvbem avatar kvanasselt avatar marliesa avatar menno94 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

xbeach-toolbox's Issues

problem plotting with posdwn = -1

error found in setup 1D and 2D example, if posdwn = -1 is used the domain plot that is generated is incorrect
suggest to change *self.posdwn to *-self.posdwn in the xbeachtools.py (both 1D and 2D)

domain plot is incorrect:
image

output is correct:
image

keep xbtools in local coordinate system

@MarliesA and @menno94 shall we keep the xbeach tools in a local coordinate system with the origin at x,y = 0,0 and let the end user rotate coordinates accordingly?

They could do that manually inside the XBeachModelSetup class without any problems (I have used this for quite a lot of models already).

The current implementation of world coordinates also does not make sense, as the coordinates shall also be transposed depending on the definition 'local' (for me this means origin at 0,0 ๐Ÿ˜€)
e.g. L 594 xnew,ynew = rotate_grid(xr,yr,-alpha) should then also be transposed

floating point bugfix

@MarliesA I removed the floating point bugfix, this does not allow me to make 1D and 2D models using the examples ipynb

could you look into this?

# prevent very small grid sizes when floating point zero goes wrong for computing var distance!

collect dependencies of toolbox

@menno94 shall we use poetry (a .toml file) for the package management + publishing to the pypi server?
(using poetry in builds works quite nicely from gitlab and an internal pypi server)

syntax and docstring of XBeachModelAnalysis

@MarliesA could you have a look at the docstring of the functions in the XBeachModelAnalysis class?

I have added some dummy docstrings to the functions already, but it would be nice to have an explanation of the parameters and settings for each of the functions (docstring). If you could add this to #11 that would be nice

checks and raises

  • seaward extend: raise user error when required extension depth is > array where attachment is requested

merge /examples and /notebooks

/examples and /notebooks are in essence the same folders within this project. One uses .ipynb's whereas the other uses .py files. I propose to stick to the notebook examples as they also show the output

wave_function

Dispersion relation in wave_function.py are not modelled correctly

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.