A faster version of DHI mikeio with some added functionalities
Project description
Installation
pip install fastmikeio
Notes
- The package currently works only with 3D sigmal layer dfsu and vertical plane dfsu files
Features
- Export the mesh directly from 3D Dfsu file using the code below:
import fastmikeio
dfsu = fastmikeio.read("3D dfsu.dfsu")
dfsu.geometry.to_mesh(output_fname)
- Extract vertical profile from 3D dfsu file
x = [2000, 2100]
y = [100, 234]
output_filename = "Vertical Profile.dfsu"
vertical = dfsu.vertical_extractor(x, y, output_filename)
- Retrive data as useful numpy array
print(dfsu) # Helper statement to get item indices
print(dfsu.n_layers)
print(dfsu.n_timesteps)
dfsu.get_data(item_idx=1, time_idx=[0, dfsu.n_timesteps-1], layer_idx=2) # (1, 2, 1, n_2d_elements)
dfsu.get_data(item_idx=1) # (1, n_timesteps, n_layers, n_2d_elements)
dfsu.get_data(reshape=False) # (n_items, n_timesteps, n_3d_elements)
dfsu.get_data() # (n_items, n_timesteps, n_layers, n_2d_elements)
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
fastmikeio-0.0.3.tar.gz
(14.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fastmikeio-0.0.3.tar.gz.
File metadata
- Download URL: fastmikeio-0.0.3.tar.gz
- Upload date:
- Size: 14.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fae165bb91c2714c3195eba5481020ff9126b065f1b844b33f42424d066fc088
|
|
| MD5 |
13c6dff0e2f17dce69c5579aa9479459
|
|
| BLAKE2b-256 |
b558090de8c13f21741b8b327446cae818f05208002d4aa381f6c51481715908
|
File details
Details for the file fastmikeio-0.0.3-py3-none-any.whl.
File metadata
- Download URL: fastmikeio-0.0.3-py3-none-any.whl
- Upload date:
- Size: 15.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
78f1f1a7db4628a551d2c4b34da198654af60266a6c58ba9859f0dbb7fa64f6c
|
|
| MD5 |
d286b47006235064421206d45815fba5
|
|
| BLAKE2b-256 |
c608c8d9a5b077140eea7b60f8dfce2b9714fc15809d57151865c9c8a0c5d89f
|