Objectives


  • Set-up a cartesian projection for the Cross section
  • Configure the axis
  • Load a netCDF file, and understand the information needed by Magics.
  • Apply a shading
  • Position the legend box
  • Add a text.

You will need to download


 

 

Setting of the cartesian projection

We want to show our Cross section in the following cartesian system:

  • The vertical coordinate system is a logarithmic axis from 1000 hPa to 200 hPa.
  • The horizontal coordinate system is a geoline axis from [50oN, 90oW] to  [30oN, 60oW]

Have a look at the  subpage documentation to learn how to setup a cartesian projection .

We just have to add 2 axis (1 vertical, 1 horizontal ) to materialise it on the plot. For backward compatibility, we have only one maxis object, the orientation is defined using the parameter axis_orientation.

Parameters to check


Useful subpage parameters

subpage_map_projection

subpage_x_axis_type
subpage_y_axis_type
subpage_x_min_latitude
subpage_x_min_longitude
subpage_x_max_latitude
subpage_x_max_longitude
subpage_y_min
subpage_y_max
Python - Setting a projection
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step1",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        )
        
plot(output, projection, horizontal, vertical)

 

Adjusting the axis

By specialising the axis, you can improve your axis visualisation.

Have a look at the Axis Documentation  to browse the possibilities.

Now, try to improve the readability of the line by specialising the horizontal axis.

Parameters to check


Useful axis parameters

axis_type

axis_tick_label_height
axis_tick_label_colour
axis_grid
axis_title
Python - adjusting the axis
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step2",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        axis_grid='on',
        axis_type='logarithmic',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid_colour='charcoal',
        axis_grid_line_style='dash',
        axis_title='on',
        axis_title_text='Pressure',
        axis_title_height=0.6,
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        axis_type='geoline',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid='on',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_line_style='dash',
        )
plot(output, projection, horizontal, vertical)

 

 

Loading the netCDF data

In this exercise, we want to visualise a matrix stored in a netCDF file. netCDF is a very generic format, and can contain a lot of data. We will  need to set up some information in order to explain to Magics which variable to plot, and how to interpret it.

The mnetcdf data action comes with a parameter list that can be found in the  netCDF Input Page.

But first, let's see what is inside our netCDF Data

ncdump section.nc
netCDF section {
dimensions:
        levels = 85 ;
        longitude = 144 ;
        latitude = 144 ;
        p15220121030000000000001_1 = 2 ;
        p15220121030000000000001_2 = 144 ;
        orography_x_values = 144 ;
        orography_y1_values = 144 ;
        orography_y2_values = 144 ;
variables:
        double levels(levels) ;
        double longitude(longitude) ;
        double latitude(latitude) ;
        double p13820121030000000000001(levels, longitude) ;

We want to display the variable p13820121030000000000001, and inform Magics that the dimensions of the matrix are described in the 2 variables levels and longitude.

The range of the vorticity values is quite small, then we would like to apply a scaling factor of 100000.

We will then just apply a basic contouring.

Parameters to check


Useful netCDF parameters

netcdf_filename

netcdf_value_variable
netcdf_field_scaling_factor
netcdf_y_variable
netcdf_x_variable
netcdf_x_auxiliary_variable
Python - Loading a Netcdf
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step3",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        axis_grid='on',
        axis_type='logarithmic',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_reference_line_style='solid',
        axis_grid_reference_thickness=1,
        axis_grid_line_style='dash',
        axis_title='on',
        axis_title_text='Pressure',
        axis_title_height=0.6,
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        axis_type='geoline',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid='on',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_line_style='dash',
        )
# Definition of the netCDF data and interpretation
data = mnetcdf(netcdf_filename = "section.nc",
      netcdf_value_variable = "p13820121030000000000001",
      netcdf_field_scaling_factor = 100000.,
      netcdf_y_variable = "levels",
      netcdf_x_variable = "longitude",
      netcdf_x_auxiliary_variable = "latitude"
    )
contour = mcont()
plot(output, projection, horizontal, vertical, data, contour)

Creating a nice shading

Now, we just create a nice polygon shading.

The list of levels we want to use is : [-200., -100., -75., -50., -30., -20., -15., -13., -11., -9., -7., -5., -3., -1., 1., 3., 5.,  7., 9., 11., 13., 15., 20., 30., 50., 75., 100., 200].

and the list of colours is : ["rgb(0,0,0.3)", "rgb(0,0,0.5)", "rgb(0,0,0.7)", "rgb(0,0,0.9)", "rgb(0,0.15,1)", "rgb(0,0.3,1)", "rgb(0,0.45,1)", "rgb(0,0.6,1)", "rgb(0,0.75,1)", "rgb(0,0.85,1)", "rgb(0.2,0.95,1)", "rgb(0.45,1,1)", "rgb(0.75,1,1)", "none", "rgb(1,1,0)","rgb(1,0.9,0)", "rgb(1,0.8,0)", "rgb(1,0.7,0)", "rgb(1,0.6,0)", "rgb(1,0.5,0)", "rgb(1,0.4,0)", "rgb(1,0.3,0)", "rgb(1,0.15,0)", "rgb(0.9,0,0)", "rgb(0.7,0,0)", "rgb(0.5,0,0)", "rgb(0.3,0,0)"],

Do not forget to turn the legend on ...

You could quickly check Contour Documentation

Parameters to check


Useful contour parameters

contour_level_selection_type

contour_level_list
contour_shade

contour_shade_method

contour_shade_colour_method

contour_shade_colour_list
legend
Python - Using a shading
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step3",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        axis_grid='on',
        axis_type='logarithmic',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_reference_line_style='solid',
        axis_grid_reference_thickness=1,
        axis_grid_line_style='dash',
        axis_title='on',
        axis_title_text='Pressure',
        axis_title_height=0.6,
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        axis_type='geoline',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid='on',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_line_style='dash',
        )
# Definition of the netCDF data and interpretation
data = mnetcdf(netcdf_filename = "section.nc",
      netcdf_value_variable = "p13820121030000000000001",
      netcdf_field_scaling_factor = 100000.,
      netcdf_y_variable = "levels",
      netcdf_x_variable = "longitude",
      netcdf_x_auxiliary_variable = "latitude"
    )
contour = mcont(contour_highlight= "off",
    contour_hilo= "off",
    contour_label= "off",
    legend='on',
    contour_level_list= [-200., -100., -75., -50., -30., -20., 
        -15., -13., -11., -9., -7., -5., -3., -1., 1., 3., 5., 
        7., 9., 11., 13., 15., 20., 30., 50., 75., 100., 200],
    contour_level_selection_type= "level_list",
    contour_shade= "on",
    contour_shade_colour_list= ["rgb(0,0,0.3)", "rgb(0,0,0.5)", 
        "rgb(0,0,0.7)", "rgb(0,0,0.9)", "rgb(0,0.15,1)", 
        "rgb(0,0.3,1)", "rgb(0,0.45,1)", "rgb(0,0.6,1)", 
        "rgb(0,0.75,1)", "rgb(0,0.85,1)", "rgb(0.2,0.95,1)", 
        "rgb(0.45,1,1)", "rgb(0.75,1,1)", "none", "rgb(1,1,0)", 
        "rgb(1,0.9,0)", "rgb(1,0.8,0)", "rgb(1,0.7,0)", 
        "rgb(1,0.6,0)", "rgb(1,0.5,0)", "rgb(1,0.4,0)", 
        "rgb(1,0.3,0)", "rgb(1,0.15,0)", "rgb(0.9,0,0)", 
        "rgb(0.7,0,0)", "rgb(0.5,0,0)", "rgb(0.3,0,0)"],
    contour_shade_colour_method= "list",
    contour_shade_method= "area_fill")
plot(output, projection, horizontal, vertical, data, contour)

Position the legend

By default, the legend is is positioned at the top of the plot. In this  exercise we want to put see our legend on a column mode on the right of the plot.

The Information about the positional mode can be found in the Legend Documentation

Parameters to check


Useful legend parameters

legend

legend_display_type

legend_box_mode

legend_box_x_position

legend_box_y_position

legend_box_x_length

legend_box_y_length
legend_box_blanking
legend_border
Python - Position the legend
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step5",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        axis_grid='on',
        axis_type='logarithmic',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_reference_line_style='solid',
        axis_grid_reference_thickness=1,
        axis_grid_line_style='dash',
        axis_title='on',
        axis_title_text='Pressure',
        axis_title_height=0.6,
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        axis_type='geoline',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid='on',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_line_style='dash',
        )
# Definition of the netCDF data and interpretation
data = mnetcdf(netcdf_filename = "section.nc",
      netcdf_value_variable = "p13820121030000000000001",
      netcdf_field_scaling_factor = 100000.,
      netcdf_y_variable = "levels",
      netcdf_x_variable = "longitude",
      netcdf_x_auxiliary_variable = "latitude"
    )
contour = mcont(contour_highlight= "off",
    contour_hilo= "off",
    contour_label= "off",
    legend='on',
    contour_level_list= [-200., -100., -75., -50., -30., -20., 
        -15., -13., -11., -9., -7., -5., -3., -1., 1., 3., 5., 
        7., 9., 11., 13., 15., 20., 30., 50., 75., 100., 200],
    contour_level_selection_type= "level_list",
    contour_shade= "on",
    contour_shade_colour_list= ["rgb(0,0,0.3)", "rgb(0,0,0.5)", 
        "rgb(0,0,0.7)", "rgb(0,0,0.9)", "rgb(0,0.15,1)", 
        "rgb(0,0.3,1)", "rgb(0,0.45,1)", "rgb(0,0.6,1)", 
        "rgb(0,0.75,1)", "rgb(0,0.85,1)", "rgb(0.2,0.95,1)", 
        "rgb(0.45,1,1)", "rgb(0.75,1,1)", "none", "rgb(1,1,0)", 
        "rgb(1,0.9,0)", "rgb(1,0.8,0)", "rgb(1,0.7,0)", 
        "rgb(1,0.6,0)", "rgb(1,0.5,0)", "rgb(1,0.4,0)", 
        "rgb(1,0.3,0)", "rgb(1,0.15,0)", "rgb(0.9,0,0)", 
        "rgb(0.7,0,0)", "rgb(0.5,0,0)", "rgb(0.3,0,0)"],
    contour_shade_colour_method= "list",
    contour_shade_method= "area_fill")
legend = mlegend(legend='on', 
    legend_display_type='continuous', 
    legend_text_colour='charcoal',         
    legend_text_font_size=0.4, 
    legend_box_mode = "positional",
    legend_box_x_position = 27.00,
    legend_box_y_position = 3.00,
    legend_box_x_length = 2.00,
    legend_box_y_length = 13.00,
    legend_box_blanking = "on",
    legend_border = "on",
    legend_border_colour='charcoal')
 plot(output, projection, horizontal, vertical, data, contour, legend)

add a Title

Last thing to do here .. We add a title to the top..

Here we will use a combination of User text and automatic text ( read from the netCDF global attribute title)

To get the automatic title, you have to use the following tag <magics_title/>

Check the Text Plotting Page for more information

Parameters to check


Useful Text parameters

text_lines

text_font_size
text_colour
text_font_style
Python - Position the legend
from Magics.macro import *
#setting the output 
output = output(    
                output_formats = ['png'],
                output_name = "xsect_step6",
                output_name_first_page_number = "off"
        )
# Setting the cartesian view
projection = mmap(
        subpage_map_projection='cartesian',
        subpage_x_axis_type='geoline',
        subpage_y_axis_type='logarithmic',
        subpage_x_min_latitude=50.,
        subpage_x_max_latitude=30.,
        subpage_x_min_longitude=-90.,
        subpage_x_max_longitude=-60.,
        subpage_y_min=1020.,
        subpage_y_max=200.,
        )
# Vertical axis
vertical = maxis(
        axis_orientation='vertical',
        axis_grid='on',
        axis_type='logarithmic',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_reference_line_style='solid',
        axis_grid_reference_thickness=1,
        axis_grid_line_style='dash',
        axis_title='on',
        axis_title_text='Pressure',
        axis_title_height=0.6,
        )
# Horizontal axis
horizontal = maxis(
        axis_orientation='horizontal',
        axis_type='geoline',
        axis_tick_label_height=0.4,
        axis_tick_label_colour='charcoal',
        axis_grid='on',
        axis_grid_colour='charcoal',
        axis_grid_thickness=1,
        axis_grid_line_style='dash',
        )
# Definition of the netCDF data and interpretation
data = mnetcdf(netcdf_filename = "section.nc",
      netcdf_value_variable = "p13820121030000000000001",
      netcdf_field_scaling_factor = 100000.,
      netcdf_y_variable = "levels",
      netcdf_x_variable = "longitude",
      netcdf_x_auxiliary_variable = "latitude"
    )
contour = mcont(contour_highlight= "off",
    contour_hilo= "off",
    contour_label= "off",
    legend='on',
    contour_level_list= [-200., -100., -75., -50., -30., -20., 
        -15., -13., -11., -9., -7., -5., -3., -1., 1., 3., 5., 
        7., 9., 11., 13., 15., 20., 30., 50., 75., 100., 200],
    contour_level_selection_type= "level_list",
    contour_shade= "on",
    contour_shade_colour_list= ["rgb(0,0,0.3)", "rgb(0,0,0.5)", 
        "rgb(0,0,0.7)", "rgb(0,0,0.9)", "rgb(0,0.15,1)", 
        "rgb(0,0.3,1)", "rgb(0,0.45,1)", "rgb(0,0.6,1)", 
        "rgb(0,0.75,1)", "rgb(0,0.85,1)", "rgb(0.2,0.95,1)", 
        "rgb(0.45,1,1)", "rgb(0.75,1,1)", "none", "rgb(1,1,0)", 
        "rgb(1,0.9,0)", "rgb(1,0.8,0)", "rgb(1,0.7,0)", 
        "rgb(1,0.6,0)", "rgb(1,0.5,0)", "rgb(1,0.4,0)", 
        "rgb(1,0.3,0)", "rgb(1,0.15,0)", "rgb(0.9,0,0)", 
        "rgb(0.7,0,0)", "rgb(0.5,0,0)", "rgb(0.3,0,0)"],
    contour_shade_colour_method= "list",
    contour_shade_method= "area_fill")
legend = mlegend(legend='on', 
    legend_display_type='continuous', 
    legend_text_colour='charcoal',         
    legend_text_font_size=0.4, 
    legend_box_mode = "positional",
    legend_box_x_position = 27.00,
    legend_box_y_position = 3.00,
    legend_box_x_length = 2.00,
    legend_box_y_length = 13.00,
    legend_box_blanking = "on",
    legend_border = "on",
    legend_border_colour='charcoal')
title = mtext(
        text_lines= ['Example of Xsection to demonstrate the use of netCDF data...', 
        '<magics_title/>'],
        text_html= 'true',
        text_justification= 'left',
        text_font_size= 0.8,
        text_colour= 'charcoal',
        )

plot(output, projection, horizontal, vertical, data, contour, legend, title)

Go to the next step...

Go back to the main page ...

1 Comment

  1. I have installed Magics in my MacBook Pro with macOS 10.13.6, and encounter segmentation fault when run this example. Detail log are:

    Process: Python [86943]
    Path: /usr/local/Cellar/python@2/2.7.15_1/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
    Identifier: Python
    Version: 2.7.15 (2.7.15)
    Code Type: X86-64 (Native)
    Parent Process: bash [95023]
    Responsible: Python [86943]
    User ID: 501
    Date/Time: 2018-08-01 17:37:33.827 +0800
    OS Version: Mac OS X 10.13.6 (17G65)
    Report Version: 12
    Bridge OS Version: 3.0 (14Y664)
    Anonymous UUID: BFFD7D1A-A327-2A97-465A-ADE2108E8352
    Sleep/Wake UUID: 9FF8AD59-C121-44EF-A20E-D66287A6FC48
    Time Awake Since Boot: 840000 seconds
    Time Since Wake: 180000 seconds
    System Integrity Protection: enabled
    Crashed Thread: 8
    Exception Type: EXC_BAD_ACCESS (SIGSEGV)
    Exception Codes: EXC_I386_GPFLT
    Exception Note: EXC_CORPSE_NOTIFY
    Termination Signal: Segmentation fault: 11
    Termination Reason: Namespace SIGNAL, Code 0xb
    Terminating Process: exc handler [0]
    Thread 0:: Dispatch queue: com.apple.main-thread
    0 libsystem_kernel.dylib 0x00007fff52321d82 __semwait_signal + 10
    1 libsystem_pthread.dylib 0x00007fff524ed824 _pthread_join + 626
    2 libMagPlus.dylib 0x00000001065cd6a4 magics::ThreadControler::wait() + 20
    3 libMagPlus.dylib 0x00000001067e2e29 magics::IsoPlot::isoline(magics::MatrixHandler&, magics::BasicGraphicsObjectContainer&) + 3337
    4 libMagPlus.dylib 0x00000001067e327e magics::IsoPlot::operator()(magics::MatrixHandler&, magics::BasicGraphicsObjectContainer&) + 238
    Thread 1:
    0 libsystem_kernel.dylib 0x00007fff52321a16 __psynch_cvwait + 10
    1 libsystem_pthread.dylib 0x00007fff524ea589 _pthread_cond_wait + 732
    2 libMagPlus.dylib 0x00000001065c9952 MutexCond::wait() + 18
    3 libMagPlus.dylib 0x00000001067d5904 magics::IsoHelper::run() + 276
    4 libMagPlus.dylib 0x00000001065ce3d9 magics::ThreadControler::execute() + 121
    5 libMagPlus.dylib 0x00000001065ce459 magics::ThreadControler::startThread(void*) + 9
    6 libsystem_pthread.dylib 0x00007fff524e9661 _pthread_body + 340
    7 libsystem_pthread.dylib 0x00007fff524e950d _pthread_start + 377
    8 libsystem_pthread.dylib 0x00007fff524e8bf9 thread_start + 13
    Thread 2:
    0 libsystem_kernel.dylib 0x00007fff52321a16 __psynch_cvwait + 10
    1 libsystem_pthread.dylib 0x00007fff524ea589 _pthread_cond_wait + 732
    2 libMagPlus.dylib 0x00000001065c9952 MutexCond::wait() + 18
    3 libMagPlus.dylib 0x00000001067d5904 magics::IsoHelper::run() + 276
    4 libMagPlus.dylib 0x00000001065ce3d9 magics::ThreadControler::execute() + 121
    5 libMagPlus.dylib 0x00000001065ce459 magics::ThreadControler::startThread(void*) + 9
    6 libsystem_pthread.dylib 0x00007fff524e9661 _pthread_body + 340
    7 libsystem_pthread.dylib 0x00007fff524e950d _pthread_start + 377
    8 libsystem_pthread.dylib 0x00007fff524e8bf9 thread_start + 13
    Thread 3:
    0 libsystem_kernel.dylib 0x00007fff52321a16 __psynch_cvwait + 10
    1 libsystem_pthread.dylib 0x00007fff524ea589 _pthread_cond_wait + 732
    2 libMagPlus.dylib 0x00000001065c9952 MutexCond::wait() + 18
    3 libMagPlus.dylib 0x00000001067d5904 magics::IsoHelper::run() + 276
    4 libMagPlus.dylib 0x00000001065ce3d9 magics::ThreadControler::execute() + 121
    5 libMagPlus.dylib 0x00000001065ce459 magics::ThreadControler::startThread(void*) + 9
    6 libsystem_pthread.dylib 0x00007fff524e9661 _pthread_body + 340
    7 libsystem_pthread.dylib 0x00007fff524e950d _pthread_start + 377
    8 libsystem_pthread.dylib 0x00007fff524e8bf9 thread_start + 13
    Thread 4:
    0 libsystem_kernel.dylib 0x00007fff52321a16 __psynch_cvwait + 10
    1 libsystem_pthread.dylib 0x00007fff524ea589 _pthread_cond_wait + 732
    2 libMagPlus.dylib 0x00000001065c9952 MutexCond::wait() + 18
    3 libMagPlus.dylib 0x00000001067d5904 magics::IsoHelper::run() + 276
    4 libMagPlus.dylib 0x00000001065ce3d9 magics::ThreadControler::execute() + 121
    5 libMagPlus.dylib 0x00000001065ce459 magics::ThreadControler::startThread(void*) + 9
    6 libsystem_pthread.dylib 0x00007fff524e9661 _pthread_body + 340
    7 libsystem_pthread.dylib 0x00007fff524e950d _pthread_start + 377
    8 libsystem_pthread.dylib 0x00007fff524e8bf9 thread_start + 13
    Thread 5:
    0 libsystem_platform.dylib 0x00007fff524deb11 _platform_memchr$VARIANT$Haswell + 81
    1 libstdc++.6.dylib 0x0000000109a157f9 std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::find_first_of(char const*, unsigned long, unsigned long) const + 73
    2 libMagPlus.dylib 0x00000001063a9a46 magics::IsoShadingAttributes::IsoShadingAttributes() + 470
    3 libMagPlus.dylib 0x000000010680798a magics::IsoShading::clone() const + 42
    4 ??? 0x00007fb018f8b3d0 0 + 140394309923792
    5 ??? 0x00007fb018f8b3e8 0 + 140394309923816
    Thread 6:
    0 libMagPlus.dylib 0x0000000106557396 magics::Colour::valid(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 38
    1 libMagPlus.dylib 0x00000001065573ff magics::MagTranslator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, magics::Colour>::operator()(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 15
    2 libMagPlus.dylib 0x000000010630b839 magics::CalculateColourTechniqueAttributes::CalculateColourTechniqueAttributes() + 2281
    3 libMagPlus.dylib 0x000000010674bd9a magics::CalculateColourTechnique::CalculateColourTechnique() + 26
    4 libMagPlus.dylib 0x00000001063a843b magics::SimpleObjectMaker<magics::CalculateColourTechnique, magics::ColourTechnique>::make() const + 27
    5 libMagPlus.dylib 0x00000001063aa4b6 magics::IsoShadingAttributes::IsoShadingAttributes() + 3142
    6 libMagPlus.dylib 0x000000010680798a magics::IsoShading::clone() const + 42
    7 ??? 0x00007fb018f8b3d0 0 + 140394309923792
    8 ??? 0x00007fb018f8b3e8 0 + 140394309923816
    Thread 7:
    0 libMagPlus.dylib 0x0000000106557396 magics::Colour::valid(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 38
    1 libMagPlus.dylib 0x00000001065573ff magics::MagTranslator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, magics::Colour>::operator()(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 15
    2 libMagPlus.dylib 0x000000010630b839 magics::CalculateColourTechniqueAttributes::CalculateColourTechniqueAttributes() + 2281
    3 libMagPlus.dylib 0x000000010674bd9a magics::CalculateColourTechnique::CalculateColourTechnique() + 26
    4 libMagPlus.dylib 0x00000001063a843b magics::SimpleObjectMaker<magics::CalculateColourTechnique, magics::ColourTechnique>::make() const + 27
    5 libMagPlus.dylib 0x00000001063aa4b6 magics::IsoShadingAttributes::IsoShadingAttributes() + 3142
    6 libMagPlus.dylib 0x000000010680798a magics::IsoShading::clone() const + 42
    7 ??? 0x00007fb018f8b3d0 0 + 140394309923792
    8 ??? 0x00007fb018f8b3e8 0 + 140394309923816
    Thread 8 Crashed:
    0 libMagPlus.dylib 0x0000000106557396 magics::Colour::valid(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 38
    1 libMagPlus.dylib 0x00000001065573ff magics::MagTranslator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, magics::Colour>::operator()(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 15
    2 libMagPlus.dylib 0x000000010630b839 magics::CalculateColourTechniqueAttributes::CalculateColourTechniqueAttributes() + 2281
    3 libMagPlus.dylib 0x000000010674bd9a magics::CalculateColourTechnique::CalculateColourTechnique() + 26
    4 libMagPlus.dylib 0x00000001063a843b magics::SimpleObjectMaker<magics::CalculateColourTechnique, magics::ColourTechnique>::make() const + 27
    5 libMagPlus.dylib 0x00000001063aa4b6 magics::IsoShadingAttributes::IsoShadingAttributes() + 3142
    6 libMagPlus.dylib 0x000000010680798a magics::IsoShading::clone() const + 42
    7 ??? 0x00007fb018f8b3d0 0 + 140394309923792
    8 ??? 0x00007fb018f8b3e8 0 + 140394309923816
    Thread 8 crashed with X86 Thread State (64-bit):
    rax: 0x0000700003d94598 rbx: 0x0000700003d94578 rcx: 0x0000000000000065 rdx: 0x0000000000000000
    rdi: 0x0000700003d946d8 rsi: 0x0000700003d946d8 rbp: 0x0000700003d946d8 rsp: 0x0000700003d94578
    r8: 0x0000000000000004 r9: 0x0000000000000000 r10: 0x000007fb01b33df2 r11: 0x00006ffefcee6710
    r12: 0x0000700003d94758 r13: 0x0000000000000000 r14: 0x00007fb018f4af60 r15: 0x00007fb01b33df20
    rip: 0x0000000106557396 rfl: 0x0000000000010202 cr2: 0x00007fb01b33e008

    Logical CPU: 2
    Error Code: 0x00000000
    Trap Number: 13

    where Thread 8 crashed. Any idea? Thanks!