Delft3D FM is an engine for hydrodynamical simulations on unstructured grids in 1D-2D-3D. It is the successor of Delft3D-FLOW and SOBEK-FLOW.
Running your Delft3D FM workload on Nerdalize
Make sure you’ve set up Nerd, our CLI.
Upload your dataset.
Please note that when uploading the simulation configuration, you need to include a “run_docker.sh” script and a “dimr_config.xml” configuration file to point to the mdu-file of the simulation that you want to run.
Also make sure to set
OutputDir = /outputin your
.mduconfig file. This way Delft3D FM knows to write the output to the right directory.
$ nerd dataset upload <path> 105.30 MiB / 194.31 MiB [========---] 51% 4s Upload complete! ID of new dataset: '<dataset-id>'
Don’t have a dataset at hand? Download our example dataset and unzip it.
Create a secret.
The Delft3D FM image is in the private Deltares Docker Hub. When using an image from a private repository you have to create a secret. This way the Nerd CLI knows you have the right to access the image.
$ nerd secret create index.docker.io --username=<dockerhub-username> --password=<dockerhub-password> --type=registry New Secret: Name: index.docker.io Type: kubernetes.io/dockerconfigjson
Start D-Flow FM.
$ nerd workload start deltares/dflowfm -s 2 --input-dataset <dataset-id> Workload created with ID: <workload-id>
Run your simulation.
$ nerd task create <workload-id> -- /bin/sh -c "cd /input; chmod +x run_docker.sh; ./run_docker.sh" Started task with ID: <task-id>
By default the amount of threads is set to the number of cores, this can be changed with environment variable
$ nerd task create <workload-id> -e OMP_NUM_THREADS=<number-of-threads> -- /bin/sh -c "cd /input; chmod +x run_docker.sh; ./run_docker.sh" Started task with ID: <task-id>
You can run tasks simultaneously with different environment variables and arguments.
Review the simulation logs (optional).
List the workload’s workers.
$ nerd workload describe <workload_id> Workload Details: ID: <workload-id> Image: deltares/dflowfm Input: Created: 18 minutes ago Workers: <worker-id> (Running)
Request the log output for a worker.
$ nerd worker logs <workload-id> <worker_id>
Check on the status of your tasks.
$ nerd task list <workload_id> TASK ID CMD OUTPUT ID STATUS CREATED <task-id>  <output-id> SUCCESS 22 minutes ago
When your task’s status is
SUCCESSit’s finished and you can continue to download the output.
Download the collection of output files.
$ nerd dataset download <output_id> <target_dir>
The output also contains a folder with all input files, as Delft3D FM writes some diagnostic files to the input folder.
Stop Delft3D FM.
$ nerd workload stop <workload_id>
You’ve run a Delft3D FM simulation. Awesome!
You can run another simulation or use your own image.
Have any questions about using Nerdalize compute?