# Path: molyso/generic/tunable.py
# def tunable(what, default, description=None):
#     """
#     Syntactic sugar helper function, to quickly get a tunable.
#     Calls: :code:`TunableManager.get_tunable(what, default)`
# 
#     :param what: tunable to look up
#     :type what: str or unicode
#     :param default: default value
#     :param description: description
#     :return: either the overridden tunable or the default value
#     :rtype: type(default)
# 
#     >>> tunable('my.tunable', 3.1415)
#     3.1415
#     """
# 
#     if description:
#         TunableManager.set_description(what, description)
# 
#     return TunableManager.get_tunable(what, default)


from ..generic.tunable import tunable
    from ..debugging.debugplot import poly_drawing_helper
import numpy as np
    import matplotlib.colors
            scatter_collector[scatter_used, pos_time_point] = parent_cell.channel.image.timepoint
            scatter_collector[scatter_used, pos_centroid] = parent_cell.centroid_1d
            # TODO different visualization?
            scatter_collector[scatter_used, pos_length] = parent_cell.length
            scatter_collector[scatter_used, pos_fluorescence_start] = \
                catch_index_error(lambda: getattr(parent_cell, 'fluorescences', [0.0])[0], 0.0)

            scatter_used += 1

        last_cell_number = len(cell.seen_as) - 1

        for nc, cell_appearance in enumerate(cell.seen_as):

            if nc == 0 and cell.parent is None:
                the_type = type_start
            elif nc == last_cell_number:
                the_type = type_junction if len(cell.children) > 0 else type_stop
            else:
                the_type = type_nothing

            scatter_collector[scatter_used, pos_type] = the_type
            scatter_collector[scatter_used, pos_time_point] = cell_appearance.channel.image.timepoint
            scatter_collector[scatter_used, pos_centroid] = cell_appearance.centroid_1d
            scatter_collector[scatter_used, pos_length] = cell_appearance.length
            scatter_collector[scatter_used, pos_fluorescence_start] = \
                catch_index_error(lambda: getattr(cell_appearance, 'fluorescences', [0.0])[0], 0.0)

            scatter_used += 1

        color = tunable('colors.visualization.track.color', '#005B82', description="Track color for visualization.")

# Path: molyso/generic/tunable.py
# def tunable(what, default, description=None):
#     """
#     Syntactic sugar helper function, to quickly get a tunable.
#     Calls: :code:`TunableManager.get_tunable(what, default)`
# 
#     :param what: tunable to look up
#     :type what: str or unicode
#     :param default: default value
#     :param description: description
#     :return: either the overridden tunable or the default value
#     :rtype: type(default)
# 
#     >>> tunable('my.tunable', 3.1415)
#     3.1415
#     """
# 
#     if description:
#         TunableManager.set_description(what, description)
# 
#     return TunableManager.get_tunable(what, default)


# Path: molyso/mm/tracking_output.py
from ..generic.tunable import tunable
    from ..debugging.debugplot import poly_drawing_helper
import numpy as np
    import matplotlib.colors

            scatter_collector[scatter_used, pos_time_point] = parent_cell.channel.image.timepoint
            scatter_collector[scatter_used, pos_centroid] = parent_cell.centroid_1d
            # TODO different visualization?
            scatter_collector[scatter_used, pos_length] = parent_cell.length
            scatter_collector[scatter_used, pos_fluorescence_start] = \
                catch_index_error(lambda: getattr(parent_cell, 'fluorescences', [0.0])[0], 0.0)

            scatter_used += 1

        last_cell_number = len(cell.seen_as) - 1

        for nc, cell_appearance in enumerate(cell.seen_as):

            if nc == 0 and cell.parent is None:
                the_type = type_start
            elif nc == last_cell_number:
                the_type = type_junction if len(cell.children) > 0 else type_stop
            else:
                the_type = type_nothing

            scatter_collector[scatter_used, pos_type] = the_type
            scatter_collector[scatter_used, pos_time_point] = cell_appearance.channel.image.timepoint
            scatter_collector[scatter_used, pos_centroid] = cell_appearance.centroid_1d
            scatter_collector[scatter_used, pos_length] = cell_appearance.length
            scatter_collector[scatter_used, pos_fluorescence_start] = \
                catch_index_error(lambda: getattr(cell_appearance, 'fluorescences', [0.0])[0], 0.0)

            scatter_used += 1

        color = tunable('colors.visualization.track.color', '#005B82', description="Track color for visualization.")

        color_alpha = tunable('colors.visualization.track.alpha', 0.3, description="Track alpha for visualization.")