Create a datalist, vessel-file & plot of the raw data

First steps in MB-System

Release the following commands inside the raw data folder work. If you have not changed directory on the Notebook where the prepending commands where released, you will still be at that location. Otherwise use %pwd to check your present working directory. The following counts for treating Kongsberg *.all files of all newer MBES like EM122/EM710/EM2040 (MB-System format mb58 which will be copied and extended to the format mb59). In general one can delete the *.all files once the data has been copied to the *.mbXX format.

Commands

Release the following commands en bloc on the Notebook :

!mbm_makedatalist -S.all -V -O datalist_raw.mb-1
!mbmakeplatform --swath=datalist_raw.mb-1 --verbose  --output=platform_MSM36_EM122.plf --platform-type-surface-vessel
!mbpreprocess --input=datalist_raw.mb-1 --platform=platform_MSM36_EM122.plf --verbose
!mbm_makedatalist -S.mb59 -P -Odatalist.mb-1 -V mbdatalist --datalistp --verbose
!mbm_plot -F-1 -Idatalist.mb-1 -G2 -N -V -O MSM36_EM122_rawBathyShaded

NOTE: Parameter S of the Perl macro mbm_makedatalist defines the vendor format. The mbmakeplatform output file name contains the cruise name and MBES used. The program mbpreprocess creates a number of auxiliary files as well as the mb59 (in this case) files. The program mbm_makedatalist creates the datalist further needed. And mbm_plot is a Perl macro that creates a cmd-script which finally produces the postscript map.

Release the created cmd-script to generate a map as postscript (*.ps)

!./MSM36_EM122_rawBathyShaded.cmd

The default created cmd-script has an issue running to the end under JupyterNotebook – it can not display the postscript map right away after generation. NOTE: Due to that issue the release of the above command get stuck. You will see a star that remains within the brackets left of the Notebooks command line (see below)

_images/got_stuck.png

In order to solve the issue simply restart the kernel (for now):

_images/restart_kernel.png

Display images in JupyterNotebook

But how do we display images on the Notebook?
Therefor, we utilize GMT to convert the postscript into jpg images.
Afterwards we point to the image which should be displayed.

Commands

!gmt ps2raster MSM36_EM122_rawBathyShaded.ps -A+n -Tj
or e.g. (!gmt psconvert MSM36_EM122_rawBathyShaded.ps -A+s5c -Tj)
from IPython.display import Image
Image(filename='MSM36_EM122_rawBathyShaded.jpg')