Function mapping between Smil and skImage¶
In this page we present which Smil functions we’ll use as reference to compare their performance and their scikit-image equivalents.
Sometimes the code needed to obtain the same results aren’t covered by a direct call to the function. In these cases, the code is directed by a note.
Functions for binary images¶
| Test | Smil function | scikit-image function | Note |
|---|---|---|---|
| erode | erode() | erosion() | |
| open | open() | opening() | |
| areaThreshold | areaThreshold() | label() remove_small_objects() |
1 |
| segmentation | watershed() + ... | watershed() + ... | 2 |
| distance | distanceEuclidean() | distance_transform_edt() | |
| label | label() fastLabel() |
label() | 3 |
| thinning | fullThin() | thin() |
Notes¶
-
skm.remove_small_objects() requires a labeled image while areaThreshold() expects a binary non labelled image as input.
-
Segmentation is seen as an application as it involves multiple functions. See : [Segmentation of binary images]
-
Smil has two functions to label binary images : label() and fastLabel(). The last is a parallelized version of parts of the first using OpenMP. We benchmarked both options and, as we’ll see the last one is fastest only on images of big size.
Functions for gray images¶
| Test | Smil function | scikit-image function | Note |
|---|---|---|---|
| erode | erode() | erosion() | |
| open | open() | opening() | |
| tophat | topHat() | white_tophat() | |
| hMinima | hMinima() | h_minima() | |
| watershed | watershed() | watershed() | |
| segmentation | watershed() + ... | watershed() + ... | 1 |
| areaOpen | areaOpen() | area_opening() |
Notes¶
- Segmentation is seen as an application as it involves multiple functions. See : [Segmentation of gray level images]