Core Module =========== .. cpp:namespace:: mln .. toctree:: :hidden: core/core_types core/images core/ranges core/neighborhood core/stl core/functional .. raw:: html

Images

See :doc:`core/images` for a description of the image concepts and image basics. .. topic:: Utilities .. table:: :widths: auto :class: full +-------------------------------------------------+------------------------------------------------------------------------------------------+ | :cpp:func:`imconcretize(f) ` | Creates a new writable image with the *geometry* of `f`. | +-------------------------------------------------+------------------------------------------------------------------------------------------+ | :cpp:func:`imchvalue(f) ` | Creates a new writable image with the *geomerty* of `f` able to store values of type `U` | +-------------------------------------------------+------------------------------------------------------------------------------------------+ | :cpp:func:`resize(g,f) ` | Resize `g` to the *geometry* of `f` | +-------------------------------------------------+------------------------------------------------------------------------------------------+ .. topic:: Fundamental types .. table:: :class: full :widths: auto +----------------------------------------------+-------------------------------------------------------------+ | :cpp:class:`ndpoint` :cpp:class:`ndpointref` | Generic :doc:`point ` that hold *n* coordinates | +----------------------------------------------+-------------------------------------------------------------+ | :cpp:class:`ndbox` :cpp:class:`ndboxref` | Generic :doc:`box ` in *n* dimension | +----------------------------------------------+-------------------------------------------------------------+ .. topic:: Fundamental image types .. table:: :class: full :widths: auto +-----------------------------------------+-------------------------+ | :cpp:any:`image2d` | Buffer-encoded 2D image | +-----------------------------------------+-------------------------+ | :cpp:any:`image3d` | Buffer-encoded 3D image | +-----------------------------------------+-------------------------+ | :cpp:any:`ndimage` | Buffer-encoded nD image | +-----------------------------------------+-------------------------+ .. topic:: Functional image views .. table:: :widths: auto :class: full +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :cpp:func:`view::transform(ima, f) ` | Views the image with a function applied to the values. | +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :cpp:func:`view::filter(ima, pred) ` | Views the image restricted to pixels whose values pass a predicate. | +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :cpp:func:`view::mask(ima, mask) ` | Views the image restricted to pixels in a binary mask. | +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :cpp:func:`view::clip(ima, roi) ` | Views the image restricted to a sub-region. | +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ | :cpp:func:`view::zip(ima1, ima2, ..., imaN) ` | Views a list of images as a single image whose values are tuples of the each image values. | +---------------------------------------------------------------+--------------------------------------------------------------------------------------------+ .. topic:: Common image operators (views) .. table:: :widths: auto :class: full +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Arithmetical | :cpp:func:`a + b `, :cpp:func:`a - b `, :cpp:func:`a * b `, :cpp:func:`a / b `, :cpp:func:`a % b ` | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Logical | :cpp:func:`a && b `, :cpp:func:`a || b `, :cpp:func:`\!a ` | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Comparison | :cpp:func:`a \< b `, :cpp:func:`a \<= b `, :cpp:func:`a == b `, :cpp:func:`a != b `, :cpp:func:`a >= b =>`, :cpp:func:`a > b >`, :cpp:func:`equalFP(a, b, eps) ` | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Conditional | :cpp:func:`view::ifelse(a, b, c) ` | +--------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. topic:: Mathematical image operator (views) .. table:: :widths: auto :class: full +----------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Component-wise | :cpp:func:`abs(a) `, :cpp:func:`sqr(a) `, :cpp:func:`pow(a, p) `, :cpp:func:`cbrt(a) `, :cpp:func:`sqrt(a) ` | +----------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Reduction | :cpp:func:`sum(a) `, :cpp:func:`prod(a) `, :cpp:func:`min(a) `, :cpp:func:`max(a) `, :cpp:func:`dot(a, b) `, :cpp:func:`cross(a, b) ` | +----------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Norms | :cpp:func:`l0norm(a) `, :cpp:func:`l1norm(a) `, :cpp:func:`l2norm(a) `, :cpp:func:`l2norm_sqr(a) `, :cpp:func:`linfnorm(a) `, :cpp:func:`lpnorm\

(a)