latinet:unicaes:opendronemap:start
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
latinet:unicaes:opendronemap:start [2023/08/25 01:25] – jan.sonntag | latinet:unicaes:opendronemap:start [2023/08/25 02:10] – jan.sonntag | ||
---|---|---|---|
Line 5: | Line 5: | ||
===== Installation ===== | ===== Installation ===== | ||
- | We are installing ODM on a Google Machine which is provided by the UNICAES. It is only turned | + | We are installing ODM on a Google Machine which is provided by the UNICAES. It is only turned |
+ | |||
+ | As some prerequisites: | ||
==== Install Docker and Docker Compose ==== | ==== Install Docker and Docker Compose ==== | ||
Line 23: | Line 25: | ||
< | < | ||
./webodm.sh restart --ssl --hostname webodm.myorg.com | ./webodm.sh restart --ssl --hostname webodm.myorg.com | ||
+ | </ | ||
+ | |||
+ | ===== Preparing Drone Images from DJI Mavic 3 Multispectral ===== | ||
+ | |||
+ | After taking the photos with the DJI M3M we need to do some postprocessing to be able to use them in ODM. Therefore it is necessary to split the multispectral from the plain RGB images. Also, the timestamps of the photos need to be matched just in case and the names need to be slightly modified as there were some hick ups in ODM from time to time. | ||
+ | We already prepared a script for that: | ||
+ | <file sh correct_filenames.sh> | ||
+ | #!/bin/bash | ||
+ | |||
+ | # Process images in the specified directory | ||
+ | process_images() { | ||
+ | local target_dir=" | ||
+ | | ||
+ | mkdir " | ||
+ | mkdir " | ||
+ | |||
+ | echo " | ||
+ | | ||
+ | for first_image in $(ls " | ||
+ | echo "Found first image: $first_image" | ||
+ | | ||
+ | timestamp=$(echo " | ||
+ | echo " | ||
+ | |||
+ | # Extract the number (XXXX) from the first image filename | ||
+ | number=$(echo " | ||
+ | echo " | ||
+ | |||
+ | mv " | ||
+ | |||
+ | for ext in " | ||
+ | echo " | ||
+ | | ||
+ | image_to_rename=$(ls " | ||
+ | | ||
+ | if [ -n " | ||
+ | new_ext=$(echo " | ||
+ | new_name=" | ||
+ | echo " | ||
+ | mv " | ||
+ | else | ||
+ | echo "No matching ${ext}.TIF files found for number: $number" | ||
+ | fi | ||
+ | done | ||
+ | done | ||
+ | } | ||
+ | |||
+ | # Check if an argument is provided | ||
+ | if [ $# -ne 1 ]; then | ||
+ | echo " | ||
+ | exit 1 | ||
+ | fi | ||
+ | |||
+ | # Call the function to process images | ||
+ | process_images " | ||
+ | </ | ||
+ | |||
+ | Just save this file somewhere you will be able to find it later as well. | ||
+ | |||
+ | We are running this script on Ubuntu. Do make it executable Don´t forget to: | ||
+ | < | ||
+ | sudo chmod +x ./ | ||
+ | </ | ||
+ | |||
+ | You can then execute the script by giving the folder with pictures inside as an argument. Example: | ||
+ | < | ||
+ | ./ | ||
</ | </ |