Skip to content

Commit

Permalink
move singularity next to HPC
Browse files Browse the repository at this point in the history
  • Loading branch information
smathermather authored Sep 27, 2024
1 parent a8bda14 commit 7306905
Showing 1 changed file with 48 additions and 48 deletions.
96 changes: 48 additions & 48 deletions source/tutorials.rst
Original file line number Diff line number Diff line change
Expand Up @@ -295,54 +295,6 @@ Cleaning up after Docker

Docker has a lamentable use of space and by default does not clean up excess data and machines when processes are complete. This can be advantageous if we need to access a process that has since terminated, but carries the burden of using increasing amounts of storage over time. Maciej Łebkowski has an `excellent overview of how to manage excess disk usage in docker <https://lebkowski.name/docker-volumes/>`_.

*****************
Using Singularity
*****************

`Singularity <https://sylabs.io/>`__ is another container platform able to run Docker images.
Singularity can be run both on local machins and in instances where the user does not have root access.
Instances where a user may not have root privlidges include HPC clusters and cloud cluster resources.
A container is a single file without anything else to install.

Build Singularity image from Docker image
=========================================
Singularity can use Docker image to build SIF image.

For latest ODM Docker image (Recommended) :

.. code:: bash
singularity build --disable-cache -f odm_latest.sif docker://opendronemap/odm:latest
For latest ODM GPU Docker image :

.. code:: bash
singularity build --disable-cache -f odm_gpu.sif docker://opendronemap/odm:gpu
Using Singularity SIF image
===========================


Once you have used one of the above commands to download and create the `odm_latest.sif` image, it can be ran using singularity.
Place your images in a directory named “images” (for example /my/project/images) , then simply run :

.. code:: bash
singularity run --bind /my/project:/datasets/code odm_latest.sif --project-path /datasets
Like with docker, additional `Options and Flags <https://docs.opendronemap.org/arguments/>`_ can be added to the command :

.. code:: bash
singularity run --bind /my/project:/datasets/code \
--writable-tmpfs odm_latest.sif \
--orthophoto-png --mesh-octree-depth 12 --ignore-gsd --dtm \
--smrf-threshold 0.4 --smrf-window 24 --dsm --pc-csv --pc-las --orthophoto-kmz \
--ignore-gsd --matcher-type flann --feature-quality ultra --max-concurrency 16 \
--use-hybrid-bundle-adjustment --build-overviews --time --min-num-features 10000 \
--project-path /datasets
*************************************
Using ODM from low-bandwidth location
*************************************
Expand Down Expand Up @@ -869,6 +821,54 @@ For instance, point clouds properties can be modified to show elevation and also

`Learn to edit <https://github.com/opendronemap/docs#how-to-make-your-first-contribution>`_ and help improve `this page <https://github.com/OpenDroneMap/docs/blob/publish/source/tutorials.rst>`_!

*****************
Using Singularity
*****************

`Singularity <https://sylabs.io/>`__ is another container platform able to run Docker images.
Singularity can be run both on local machins and in instances where the user does not have root access.
Instances where a user may not have root privlidges include HPC clusters and cloud cluster resources.
A container is a single file without anything else to install.

Build Singularity image from Docker image
=========================================
Singularity can use Docker image to build SIF image.

For latest ODM Docker image (Recommended) :

.. code:: bash
singularity build --disable-cache -f odm_latest.sif docker://opendronemap/odm:latest
For latest ODM GPU Docker image :

.. code:: bash
singularity build --disable-cache -f odm_gpu.sif docker://opendronemap/odm:gpu
Using Singularity SIF image
===========================


Once you have used one of the above commands to download and create the `odm_latest.sif` image, it can be ran using singularity.
Place your images in a directory named “images” (for example /my/project/images) , then simply run :

.. code:: bash
singularity run --bind /my/project:/datasets/code odm_latest.sif --project-path /datasets
Like with docker, additional `Options and Flags <https://docs.opendronemap.org/arguments/>`_ can be added to the command :

.. code:: bash
singularity run --bind /my/project:/datasets/code \
--writable-tmpfs odm_latest.sif \
--orthophoto-png --mesh-octree-depth 12 --ignore-gsd --dtm \
--smrf-threshold 0.4 --smrf-window 24 --dsm --pc-csv --pc-las --orthophoto-kmz \
--ignore-gsd --matcher-type flann --feature-quality ultra --max-concurrency 16 \
--use-hybrid-bundle-adjustment --build-overviews --time --min-num-features 10000 \
--project-path /datasets
***************************************************
ClusterODM, NodeODM, SLURM, with Singularity on HPC
Expand Down

0 comments on commit 7306905

Please sign in to comment.