

.. _sphx_glr_auto_examples_filters_plot_frangi.py:


=============
Frangi filter
=============

The Frangi and hybrid Hessian filters can be used to detect continuous
edges, such as vessels, wrinkles, and rivers.




.. image:: /auto_examples/filters/images/sphx_glr_plot_frangi_001.png
    :align: center





.. code-block:: python


    from skimage.data import camera
    from skimage.filters import frangi, hessian

    import matplotlib.pyplot as plt

    image = camera()

    fig, ax = plt.subplots(ncols=3)

    ax[0].imshow(image, cmap=plt.cm.gray)
    ax[0].set_title('Original image')

    ax[1].imshow(frangi(image), cmap=plt.cm.gray)
    ax[1].set_title('Frangi filter result')

    ax[2].imshow(hessian(image), cmap=plt.cm.gray)
    ax[2].set_title('Hybrid Hessian filter result')

    for a in ax:
        a.axis('off')

    plt.tight_layout()
    plt.show()

**Total running time of the script:** ( 0 minutes  0.995 seconds)



.. only :: html

 .. container:: sphx-glr-footer


  .. container:: sphx-glr-download

     :download:`Download Python source code: plot_frangi.py <plot_frangi.py>`



  .. container:: sphx-glr-download

     :download:`Download Jupyter notebook: plot_frangi.ipynb <plot_frangi.ipynb>`


.. only:: html

 .. rst-class:: sphx-glr-signature

    `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.readthedocs.io>`_
