Skip to main content

`meshkernel` is a library which can be used to manipulate meshes.

Project description

MeshKernelPy

Quality Gate Status PyPI version

MeshKernelPy is a library for creating and editing meshes. It supports 1D and 2D unstructured meshes. Support for curvilinear meshes is planned. The underlying C++ library MeshKernel can be found here.

Installation

Windows

The library can be installed from PyPI by executing

pip install meshkernel

Linux

Currently, we only offer wheels specific to Deltares' CentOS machines. We plan to release a manylinux wheel at PyPI in the future.

Examples

Creating a triangular mesh inside a polygon

In this example a mesh is created by discretizing the polygon perimeter with the desired edge length.

Mesh orthogonalization

Finite volume staggered flow solvers require the mesh to be as much orthogonal as possible. MeshKernel provides an algorithm to adapt the mesh and achieve a good balance between mesh orthogonality and smoothness.

Mesh refinement

A mesh can be refined in areas based on samples or polygon selections.

License

MeshKernelPy uses the MIT license. However, the wheels on PyPI bundle the LGPL licensed MeshKernel. Please make sure that this fits your needs before depending on it.

Contributing

In order to install MeshKernelPy locally, please execute the following line inside your virtual environment

pip install -e .[tests, lint, docs]

Also make sure that your editor is configured to format the code with black and isort. When modifying Jupyter notebooks, the jupyterlab-code-formatter can be used.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

meshkernel-1.0.0.tar.gz (959.6 kB view hashes)

Uploaded Source

Built Distributions

meshkernel-1.0.0-py3-none-win_amd64.whl (339.1 kB view hashes)

Uploaded Python 3 Windows x86-64

meshkernel-1.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (744.5 kB view hashes)

Uploaded Python 3 manylinux: glibc 2.17+ x86-64

meshkernel-1.0.0-py3-none-macosx_10_9_x86_64.whl (971.7 kB view hashes)

Uploaded Python 3 macOS 10.9+ x86-64

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page