Next Article in Journal
A Lightweight Hybrid Mobile Groupcasting Protocol for Spatially Heterogeneous Sink Groups in WSNs
Previous Article in Journal
A Hierarchical 54 V/12 V Dual-Plane Multi-Phase DC Power Delivery Architecture for High-Computing-Power AI Servers
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

MFJD-Seg: Morphological Fitting Meets Jeffreys Divergence for Efficient Active Contour Segmentation

1
School of Mechano-Electronic Engineering, Suzhou Polytechnic University, Suzhou 215104, China
2
School of Mechanical and Electrical Engineering, Soochow University, Suzhou 215137, China
3
School of Computer Science and Engineering, Southeast University, Nanjing 210096, China
*
Author to whom correspondence should be addressed.
Electronics 2026, 15(13), 2972; https://doi.org/10.3390/electronics15132972
Submission received: 29 May 2026 / Revised: 25 June 2026 / Accepted: 3 July 2026 / Published: 7 July 2026

Abstract

Image segmentation in complex scenes remains challenging due to intensity inhomogeneity, intricate textures, and noise interference. Traditional active contour models (ACMs) offer topological adaptability while suffering from over-segmentation and boundary leakage under such conditions. In this paper, we propose MFJD-Seg, a novel ACM that integrates morphological fitting with an energy formulation derived from Jeffreys divergence for robust and efficient image segmentation. Morphological erosion and dilation are applied to construct foreground and background fitting images, which capture fine-grained structural features while suppressing background interference. Subsequently, a symmetric discrepancy consistent with Jeffreys divergence is leveraged to quantify the statistical difference between the original image and the fitting representations, enabling the compact construction of an unbiased energy function. An arctangent energy constraint and mean filtering are further incorporated to stabilize contour evolution and suppress redundant artifacts. Extensive experiments on BSDS, ADE20K, and COCO datasets show that MFJD-Seg achieves the best mIoU and mDSC in comparisons with five representative ACMs and five mainstream deep learning segmentation models, improving ACM baselines by up to 4.8% in both metrics while maintaining the highest FPS among ACMs and competitive speed against deep learning counterparts. These results verify the superior segmentation capabilities of MFJD-Seg in challenging imaging scenarios.

1. Introduction

Image segmentation represents a fundamental and indispensable component within the broad landscape of computer vision tasks, including but not limited to autonomous driving [1,2,3], industrial manufacturing [4,5], medical imaging [6,7,8], and satellite remote sensing [9,10]. Owing to their inherent topological adaptability and dynamic convergence properties, active contour models (ACMs) have emerged as a prominent class of segmentation methods [11,12,13,14,15,16]. Leveraging the level set method [17], ACMs reformulate the segmentation process as the evolution of closed contours, which is driven by the minimization of a predefined energy function.
However, ACMs frequently struggle with images characterized by severe intensity inhomogeneity and sophisticated textural patterns. Previous works, exemplified by [18,19], attempt to exploit local intensity information within spatial sub-regions through operations including clustering, differentiation, and diffusion. The seminal Chan–Vese (CV) model [20] guides contour evolution by minimizing the global intensity discrepancy. To enhance robustness against intensity inhomogeneity, the RSF model [21] introduces local fitting terms constructed via double integral formulations. The SDCos_ACLS model [22] leverages sparse decomposition to extract clean co-saliency priors from image ensembles, which constrains the search space and boosts performance in feature-deficient scenarios. While these strategies mitigate the impact of intensity inhomogeneity to a certain degree, they remain susceptible to over-segmentation when processing intricate structures or overlapping objects. Edge-based ACMs [23,24] facilitate segmentation by identifying regional edges defined by abrupt intensity gradient transitions. The geodesic active contour (GAC) model [25] interprets the relationship between the target region and the active contour through the lens of minimal distance curves, thereby constructing an edge detector to localize salient intensity mutations. The ISDDT model [26] employs predetermined second-order differential cues to drive the contour, enhancing iteration speed and noise suppression. Despite their efficacy in capturing specific textural features, these methods face performance degradation under noise interference, leading to unstable edge localization in cluttered environments. Other approaches seek to construct energy functions by synergistically combining regional information with edge features [27,28]. These models often comprise a weighted summation of region and edge terms, with adaptive coefficients to balance the contribution of each component. The GLMF model [29] constructs fitting error maps by integrating both global and local statistics, facilitating the design of a hybrid signed pressure function for energy iteration. The ACFDI model [30] employs Fourier-derived frequency information to formulate regional energy, utilizing the information gap between spectral bands to delineate object boundaries in complex scenes. While offering enhanced versatility, these models suffer from limited parameter robustness.
These deficiencies can be largely attributed to the design of the driving source for the evolving contour, where the description of the shared and distinct characteristics is insufficient to accurately resolve local geometric structures and withstand the interference of noise and parametric fluctuations. This shifts the objectives from crafting additional calibration terms to stabilize the existing architecture toward seeking operators that intrinsically provide a preserved and resilient description of image information. As a mainstream pre-processing method for image analysis, morphological operators extract local minima and maxima within a structuring element and preserve the topological structure of salient regions while suppressing noise and reconnecting fragmented boundaries [31,32]. These properties are well aligned with the demands of contour evolution, yielding structure-preserving fitting representations that remain stable under intricate textures and interference while alleviating segmentation errors. In parallel, Jeffreys divergence is a widely used measure of the dissimilarity between probability distributions [33,34]. Its symmetry endows the discrepancy with directional invariance, while its distribution-aware nature renders it insensitive to the absolute magnitude of grayscale intensities. These characteristics ensure an unbiased energy formulation, in which the inward and outward evolution forces are inherently balanced, yielding stable convergence with enhanced parameter robustness.
Based on the above analysis, we propose MFJD-Seg, a novel ACM based on morphological grayscale fitting and a Jeffreys divergence-based energy formulation, which is designed to effectively segment images with severe intensity non-uniformity and multifaceted textural representations. We apply morphological dilation and erosion to local regions to extract salient structural features while suppressing background interference. Based on the refined grayscale information, regional fitting images are constructed to characterize the ideal target representation. By leveraging a symmetric discrepancy coherent with Jeffreys divergence to quantify the difference between the fitting images and the original image, we formulate an unbiased and discriminative energy function. Morphological operators improve the stability of the regional representations, while Jeffreys divergence converts these representations into a robust contour-driving force. Their integration ensures precise localization of target boundaries with high topological fidelity. Notably, since the energy term is pre-calculated before the onset of level set iterations, MFJD-Seg exhibits remarkable computational efficiency. In summary, our contributions are as follows:
  • Morphological dilation and erosion are utilized to refine regional grayscale information and strengthen foreground saliency, which mitigates the impact of intensity inhomogeneity and regularizes intricate textural patterns.
  • Jeffreys divergence is combined with the morphological fitting images to achieve one-shot construction of the energy function, enabling robust boundary localization while reducing computational overhead.
  • Extensive experiments demonstrate that MFJD-Seg consistently surpasses strong baselines across segmentation accuracy and efficiency, establishing its effectiveness in general segmentation tasks.

2. Related Work

This section first provides a brief overview of established ACMs. Then, the theoretical foundations of Jeffreys divergence and morphological operators underlying MFJD-Seg are detailed.

2.1. Active Contour Segmentation

ACMs have evolved considerably over the past decades, proving highly effective for various image segmentation objectives. Let I : Ω R 2 be the image domain, where a closed contour splits the domain into two disjoint regions Ω 1 and Ω 2 . The energy function for the classical CV model [20] is formulated as:
E C V ϕ = λ 1 Ω 1 I x c 1 2 H ε ϕ x d x + λ 2 Ω 2 I x c 2 2 H ε ϕ x d x + ν Ω δ ε ϕ x ϕ x d x ,
where x represents the coordinate of an arbitrary pixel; c 1 and c 2 denote the average intensities of Ω 1 and Ω 2 , respectively. The parameters λ 1 , λ 2 , and ν are constant coefficients, ϕ represents the level set function, and ∇ is the gradient operator. Furthermore, H ε x signifies the Heaviside function, and δ x denotes the corresponding Dirac delta derivative, defined as:
H ε x = 1 2 1 + 2 π arctan x ε δ ε x = 1 π · ε ε 2 + x 2 ,
where ε is the regularization coefficient. The CV model is proficient at handling images with simple intensity distributions, while its performance is compromised by limited information modeling when confronted with non-uniform illumination and sophisticated intensity patterns. Nevertheless, it represents a seminal contribution to the development of modern ACMs. LATE extends the CV model by leveraging Taylor expansion to characterize regional grayscale, which alleviates the high-contrast interference caused by intensity inhomogeneity [35]. AVLSM [36] incorporates an adaptive-scale bias field correction term and a tailored denoising term to enhance robustness against non-uniform illumination. CLSMA [37] adopts a convex level set method to transform the segmentation process into a convex optimization problem, and a multiplicative-additive model is constructed to retain key information and extract features. Despite these advances, existing methods remain limited in computational efficiency and robustness, particularly for images with intensity non-uniformity, intricate structural patterns, and multi-color distributions.

2.2. Jeffreys Divergence

Jeffreys divergence is a widely utilized measure for quantifying the dissimilarity between two probability distributions. As a region-wise integral of a pointwise discrepancy, Jeffreys divergence conforms naturally to the variational form of the active contour energy, allowing the interior and exterior of the contour to be expressed as two symmetric integral terms without auxiliary aggregation. Given two continuous probability distributions P and Q defined over a space X , the standard Jeffreys divergence is calculated as:
D J P     Q = X P x Q x log P x Q x d x ,
where P x Q x introduces symmetry to the divergence calculation, ensuring D J ( P | | Q ) = D J ( Q | | P ) holds for all distributions. The key properties of Jeffreys divergence are (i) non-negativity, where the divergence remains greater than or equal to zero and vanishes if and only if P = Q , serving as a robust measure where an increasing divergence value quantifies a pronounced lack of similarity between the two probability distributions, and (ii) symmetry, which ensures a commutative distance such that J ( P     Q ) = J ( Q     P ) and overcomes the inherent directional sensitivity by aggregating information gains into a unified measure of statistical discrepancy. Within the proposed framework, this property ensures that the contour evolution remains invariant to whether the current region is designated as the target or the background, thereby eliminating potential asymmetric directional biases. Note that the grayscale representations proposed by our framework are not normalized probability distributions, indicating that this formulation is not a strict probabilistic Jeffreys divergence in the classical sense. Instead, it is a Jeffreys divergence-inspired symmetric discrepancy measure designed for efficient energy modeling in contour evolution.

2.3. Image Grayscale Morphology

As a natural extension of binary morphology, grayscale morphology is designed to probe and transform local image features. Erosion and dilation are the two primary morphological operators, which are characterized by the extraction of local minimum and maximum values within a specified image neighborhood, respectively. The erosion operator is defined as:
I b x = min z B I x + z ,
where I ( x ) denotes the grayscale value of the input image at coordinate x, z represents a local image domain centered at x, and B signifies the spatial domain of the structuring element. This operation effectively suppresses isolated bright noise and eliminates structural adhesions between disparate regions. The dilation operator is formulated as:
I b x = max z B I x z ,
this operation amplifies low-contrast details within the target domain and elevates their saliency during the segmentation process. Distinct from other feature extraction methods, morphological operators exhibit excellent shape fidelity and topological preservation, preventing feature collapse in the presence of local pixel anomalies. This characteristic is intrinsically aligned with the active contour evolution, which is also a topological transformation that transcends strict pixel-wise boundary constraints.

3. Proposed Method

To reconcile the trade-off between accuracy and efficiency in segmenting images with multifaceted interference, we introduce MFJD-Seg. This novel ACM leverages morphological fitting operators to distill fine-grained structural features and employs Jeffreys divergence to construct an unbiased energy function. The framework of MFJD-Seg is visualized in Figure 1.

3.1. Construction of Morphological Fitting Images

To effectively extract local grayscale information while suppressing background interference, we construct morphological fitting images by applying erosion and dilation operators to the input image I ( x ) . The morphological fitting functions characterize the ideal grayscale distributions of the target regions, which subsequently guide the construction of the energy function. Specifically, the erosion operator extracts the minimum intensity value within the structuring element neighborhood, which corresponds to the fitting function for the foreground region formulated as
I 1 f x = ( I b ) ( x ) = min z B { I ( x + z ) } I 2 f x = ( I b ) ( x ) = max z B { I ( x z ) } ,
where B represents the spatial domain of the structuring element, and z indexes the local neighborhood centered at x. We define B as a circular binary matrix as follows:
B x = 1 , if x 2 ω 0 , otherwise ,
where ω is the size of B. The shape-preserving property of erosion and dilation stems from the order-statistic nature of the min and max operators, which extracts local extrema without altering the connectivity of salient regions. Defining B as a circular element further makes the two operations isotropic, contracting or expanding regions uniformly in all directions. As shown in Figure 2, we compare the effects under horizontal, vertical, rectangular, and circular structuring elements. The horizontal element blurs upright structures such as the wheels and front frame, while the vertical element produces lines that break horizontal boundaries. The rectangular element leaves square patterns along the curved windshield and lower areas. In contrast, the circular element keeps all these boundaries smooth and preserves their shapes, introducing no orientation-dependent distortion. Equation (7) ensures that the erosion and dilation operations are isotropic, thereby preserving the original topological structures during the feature extraction process. The erosion operation effectively captures the dark structural features and suppresses isolated bright noise, which is particularly advantageous for segmenting targets with complex textures. Conversely, the dilation operation amplifies low-contrast details and connects fragmented boundaries, enhancing their intensities.

3.2. Energy Function Formulation

Based on the morphological fitting images, we formulate the energy function by leveraging a Jeffreys divergence-inspired symmetric discrepancy to measure the statistical dissimilarity between the original image and the fitting representations. Since raw grayscale intensities are not probability distributions in the strict sense and may contain zero values, we first define positive regularized grayscale representations as I ˜ ( x ) = I ( x ) + η and I ˜ i f ( x ) = I i f ( x ) + η , where η > 0 is a small constant used to guarantee the validity of the logarithmic ratio and avoid undefined values caused by zero intensities. This is a standard numerical regularization strategy used to avoid division by zero and unstable logarithmic evaluation when grayscale values are zero or close to zero. Based on these representations, the proposed energy is formulated as:
E = i = 1 n Ω i I ˜ x I ˜ i f x log I ˜ x I ˜ i f x d x ,
where n is the number of sub-regions into which the original image domain is partitioned. The closed nature of the active contour ensures that the image domain is divided into two distinct sub-regions, namely n = 2 . Therefore, the energy function is further rewritten as:
E = Ω in I ˜ x I ˜ 1 f x log I ˜ x I ˜ 1 f x d x + Ω out I ˜ x I ˜ 2 f x log I ˜ x I ˜ 2 f x d x ,
where Ω in and Ω out refer to the image domains inside and outside the contour, respectively. Jeffreys divergence introduces asymmetry compensation, which eliminates directional bias and ensures robust handling of intensity variations on both sides of the contour.
To integrate the energy function with the level set ϕ , we leverage the Heaviside function to reformulate Equation (9) as:
E MFJD = Ω I ˜ ( x ) I ˜ 1 f ( x ) log I ˜ ( x ) I ˜ 1 f ( x ) · ( 1 H ( ϕ ) ) d x + Ω I ˜ ( x ) I ˜ 2 f ( x ) log I ˜ ( x ) I ˜ 2 f ( x ) · H ( ϕ ) d x ,
where H s denotes the Heaviside step function. To maintain the continuity of the energy function, we formulate its smoothed approximation as:
H s = 1 1 + e s / ε δ s = H s = e s / ε ε 1 + e s / ε 2 ,
where ε is a tunable constant, and δ s is the derivative of H s . Figure 3 depicts the comparison between the original H ( s ) and its smoothed approximation under different ε , and we set ε = 0.5 for our model. The initial level set function is defined as:
ϕ 0 = c 0 , x Ω in Ω in 0 , x Ω in c 0 , x Ω Ω in ,
where c 0 is a constant. Under this definition, the projections of ϕ via H approach 0 and 1 for the interior and exterior regions of the contour, respectively. Consequently, the segmentation process is transformed into the iteration of ϕ without information loss.

3.3. Level Set Evolution

The energy function is minimized using the standard gradient descent method. By computing the Gateaux derivative of E MFJD with respect to ϕ , we derive the gradient flow equation as follows:
ϕ t = E MFJD ϕ = δ ϕ · e MFJD ,
where e MFJD is the data-driven term as:
e MFJD = I ˜ x I ˜ 2 f x log I ˜ x I ˜ 2 f x I ˜ x I ˜ 1 f x log I ˜ x I ˜ 1 f x .
Given the diversity and disparate contrast levels of various image categories, the range fluctuations of e MFJD often lead to system instability. We utilize the arctangent function as an energy constraint term to bolster robustness and sharpen the responsiveness near the zero point. Therefore, Equation (13) is further rewritten as:
ϕ t = δ ϕ · 2 π arctan e MFJD ,
where the range of e MFJD is constrained within the interval ( 1 , 1 ) . As shown in Figure 4, we visualize e MFJD along the 120th row of a 300 × 225 natural image, comparing the fluctuation curves before and after applying the constraint. It is evident that the unconstrained values exhibit drastic oscillations, which can lead to either aggressive or excessive contour evolution and compromise the segmentation quality.

3.4. Numerical Implementation

The numerical solution of the level set evolution equation is computed using finite difference schemes on a rectangular grid. Therefore, Equation (15) is further expressed as:
ϕ n + 1 = ϕ n Δ t · δ ϕ 2 π arctan e MFJD .
To maintain the signed distance property of ϕ , i.e., the equivalence between Equation (9) and Equation (10), we apply a regularization function to ϕ after each iteration as follows:
ϕ R = sigatan 30 · ϕ n + 1 sigatan s = sign s 2 π arctan s 2 .
While the contour encompasses the boundaries located at the target edges, it may simultaneously include noise artifacts in non-edge areas. We utilize mean filtering to suppress this interference, as defined by:
ϕ L = mean ϕ R x Ω z ,
where Ω z denotes a k × k mean filtering window centered at pixel z. We provide the implementation steps of MFJD-Seg in Algorithm 1.
Algorithm 1 Pseudocode for MFJD-Seg
Input: Original image I, structuring element size ω , mean filtering window size k, iteration step size Δ t , and iteration number N.
Initialize:  ϕ ϕ 0
  1:
Pre-compute morphological fitting images I 1 f and I 2 f using Equation (6).
  2:
Calculate the data-driven term e MFJD based on Jeffreys divergence using Equation (14).
  3:
while  i N  do
  4:
        Compute δ ( ϕ ) with Equation (11).
  5:
        Update ϕ i + 1 using Equation (16).
  6:
        Apply the regularization function Equation (17) to obtain ϕ R .
  7:
        Perform mean filtering using Equation (18) to obtain ϕ L .
  8:
      if  ϕ i + 1 ϕ i 0.001  then
  9:
                 Break iteration.
10:
       end if
11:
end while
12:
return The final zero level set ϕ F = 0 as the target contour.

4. Experiments

4.1. Setup

Datasets. To evaluate the performance of MFJD-Seg, we adopt three publicly available datasets: BSDS [38], ADE20K [39], and COCO [40]. The Berkeley Segmentation Dataset (BSDS) is a foundational benchmark for the development and evaluation of image segmentation and boundary detection algorithms, and it contains 500 natural images with human-annotated ground truth references. ADE20K is a large-scale dataset for scene parsing and segmentation, featuring dense pixel-level annotations across 150 semantic categories and 20,210 images. COCO is an extensive benchmark engineered to advance research in object detection, instance segmentation, and image captioning. It comprises 20,000 natural images with fine-grained annotation across 80 categories.
Metrics. We report segmentation results using mean Intersection over Union (mIoU) and mean Dice Similarity Coefficient (mDSC), which are calculated as:
mIoU = E D T P T P + F P + F N ,
mDSC = E D 2 · T P 2 · T P + F P + F N ,
where T P , F P , and F N denote the number of true positives (correctly predicted target pixels), false positives (background pixels incorrectly classified as target), and false negatives (missed target pixels), respectively, and D represents the test dataset. We also report FPS (Frames Per Second) to evaluate the computational efficiency.
Baselines. We compare the proposed MFJD-Seg with five strong ACMs: GADF [41], ACFDI [30], FeaACM [42], SIRE [43], and SDCos_ACLS [22]. Each of them leverages methodological innovations based on active contour evolution to facilitate efficient image segmentation. We adopt another five deep learning segmentation models for performance comparison, including SegFormer [44], E2EC [45], EfficientViT [46], U2Seg [47], and CGViT [48]. These methods are selected to cover both representative ACMs and strong deep segmentation models. The ACM baselines include advanced variants with different region, boundary, and feature modeling strategies, while the deep models include CNN-based and transformer-based architectures. Comparison with these methods effectively validates the competitive edge and top-tier performance of MFJD-Seg.
Implementation Details. Unless otherwise specified, we set the structuring element size ω = 15 , mean filtering window size k = 7 , time step Δ t = 0.1 , and maximum iteration number N = 50 . Note that η = 10 4 is fixed for all experiments and is not used as a tunable parameter, since its purpose is only to guarantee numerical stability rather than to improve segmentation performance. For deep learning baselines, we use their official pretrained weights, and perform fine-tuning on the same training sets of the three datasets, respectively. Across the entire training pipeline, we fix the number of epochs at 100 and the learning rate at 3 × 10 4 . Data augmentation is applied through random horizontal flipping and random cropping to 512 × 512 for all training sets. All experiments are conducted on a single A100 40 GB GPU.

4.2. Main Results

We compare MFJD-Seg against five representative ACMs on the BSDS, ADE20K, and COCO datasets. As reported in Table 1, MFJD-Seg consistently surpasses all baselines in both segmentation accuracy and inference efficiency. On BSDS, it achieves 89.7% mIoU and 93.4% mDSC, outperforming the strongest baseline FeaACM by 4.7% and 4.6% while attaining the highest throughput of 50.7 FPS. On ADE20K, MFJD-Seg yields 52.4% mIoU and 55.6% mDSC, with absolute gains of 4.8% and 4.7% over the second-best SIRE. A similar trend holds on the most challenging benchmark COCO, where MFJD-Seg attains 47.5% mIoU and 45.7% mDSC, exceeding FeaACM by 4.8% on both metrics. Figure 5 visualizes the segmentation results on six representative images. In the first row, GADF and ACFDI generate fragmented contours along the branch, and SIRE and SDCos_ACLS leave portions of the body uncovered, whereas MFJD-Seg delineates both the bird silhouette and the thin branch, demonstrating the topological preservation of the morphological fitting operators. The second row is dominated by low-contrast interactions, where baselines exhibit varying degrees of boundary leakage while MFJD-Seg accurately localizes the target. In the third row, the parked car shares similar grayscale statistics with its surroundings, leading competitors to either over-segment into the architectural edges or miss the lower boundary. Across the last three rows, competing baselines suffer from under-segmentation and mislocalization, whereas MFJD-Seg consistently yields desirable results, validating its robustness under textural heterogeneity, edge ambiguity, and bright interference.
We also benchmark our approach against mainstream deep learning segmentation methods. As shown in Table 2, MFJD-Seg achieves the best mIoU and mDSC on all three datasets. Although several counterparts obtain higher FPS on specific datasets, MFJD-Seg maintains competitive efficiency while delivering more robust overall accuracy. Figure 6 presents qualitative comparisons between MFJD-Seg and representative deep learning segmentation models. Although the learning-based methods capture the coarse object regions, they suffer from boundary discontinuity, mask fragmentation, and background leakage. Benefiting from the topological property of the evolving contour, MFJD-Seg produces highly consistent target boundaries. The results indicate that the morphological fitting provides fine-grained regional features that suppress segmentation errors, while Jeffreys divergence-based energy function transforms these features into an unbiased driving force. Their cooperation allows MFJD-Seg to maintain precise segmentation in images with high-intensity inhomogeneity.

4.3. Comparison with Segmentation Foundation Models

We also evaluate the performance of MFJD-Seg against prevailing segmentation foundation models, including the classic Segment Anything Model (SAM) [49] and two of its prominent variants, TS-SAM [50] and COD-SAM [51]. Both TS-SAM and COD-SAM build upon the foundational SAM framework, integrating customized optimizations for intricate backgrounds and anomaly detection tasks. We directly employ their official open-source weights to conduct the segmentation experiments without further fine-tuning, and all input images are cropped to 512 × 512 to ensure consistency. As shown in Table 3, TS-SAM achieves the highest mIoU and mDSC, confirming that SAM-based variants are indeed strong baselines. Although MFJD-Seg does not obtain the best accuracy, it still achieves competitive segmentation performance, reaching 89.7/93.4 on BSDS, 52.4/55.6 on ADE20K, and 47.5/45.7 on COCO in terms of mIoU/mDSC. Meanwhile, MFJD-Seg maintains a clear efficiency advantage, reaching 50.7 FPS on BSDS, 43.8 FPS on ADE20K, and 45.4 FPS on COCO, which are substantially higher than those of the three SAM-based methods. These results indicate that MFJD-Seg remains competitive overall and provides a more favorable trade-off between segmentation accuracy and inference efficiency.

4.4. Efficiency Analysis

To further evaluate the proposed method, the computational efficiency is fully reported. Since ACMs are unsupervised analytical approaches, we quantify their algorithmic complexity using the standard Big-O notation O ( f ( n ) ) . For deep learning baselines, we report the number of trainable parameters (Params), the inference GPU memory footprint (GPU Mem.), and the giga floating point operations per second (GFLOPs). As shown in Table 4, MFJD-Seg exhibits lower computational complexity than the compared ACMs. Specifically, its time complexity is O ( N · P ) and its space complexity is O ( P ) , indicating that the proposed method scales linearly with both the iteration number and the image size. In contrast, GADF and ACFDI involve additional sorting-related operations, resulting in a time complexity of O ( N · P log P ) . FeaACM, SIRE, and SDCos_ACLS further depend on the feature dimension d, leading to higher time or space costs. Table 5 demonstrates that MFJD-Seg has a substantially lower model complexity than the compared deep learning models, which require tens to hundreds of millions of parameters and nontrivial GPU memory during inference. SAM and COD-SAM are particularly expensive, with 636.00 M and 647.20 M parameters and more than 3850 GFLOPs, respectively. In contrast, MFJD-Seg is training-free, with no parameter storage overhead and requiring only 1.22 GFLOPs. These results suggest that MFJD-Seg is lightweight and efficient, especially in scenarios where computational cost is critical.

4.5. Performance on Noise Interference

We conduct additional comparative experiments to evaluate the robustness of MFJD-Seg under different noisy imaging conditions. Three representative noise types are selected for segmentation experiments: Gaussian noise with a mean of 0 and a variance of 0.05, salt-and-pepper noise with a density of 0.1, and Poisson noise. As reported in Table 6, MFJD-Seg consistently achieves the best mIoU, mDSC, and FPS on all three datasets under the three noise types. Compared with the strongest competing baseline, MFJD-Seg improves mIoU by 6.8–8.0% and mDSC by 6.8–8.9% across different noise settings, while maintaining the highest inference speed. Observed from Figure 7, Figure 8 and Figure 9, existing ACMs tend to produce fragmented contours, boundary leakage, or missed target regions under noise interference, especially under Gaussian and salt-and-pepper noise. In contrast, MFJD-Seg preserves complete object structures and accurate boundary localization. These results demonstrate that the proposed morphological fitting and Jeffreys divergence-inspired energy formulation provide robust segmentation performance under diverse noise degradations. We attribute the robustness of MFJD-Seg in noisy segmentation scenarios to the ability of morphological fitting to suppress isolated noise while preserving the structure topology. Furthermore, Jeffreys divergence-based energy function is insensitive to the absolute magnitude of intensities, which prevents grayscale fluctuations.

5. Ablations

To systematically assess the robustness of MFJD-Seg, we conduct a series of ablation studies on the proposed morphological fitting strategy, the energy formulation based on Jeffreys divergence, the constraint term, the mean filtering operation, and key parameter settings.

5.1. Effectiveness of Morphological Fitting

The proposed morphological fitting algorithm constructs foreground and background fitting images through grayscale erosion and dilation, thereby converting local structural elements into stable regional descriptors for contour evolution. Specifically, we replace the proposed morphological fitting (MF) with the global mean (GM) proposed in [20], the Gaussian-weighted local mean (GWLM) proposed in [21], and local mean filtering (LMF) proposed in [52] to conduct comparative experiments. As reported in Table 7, replacing the proposed morphological fitting with the global mean leads to the weakest performance across all datasets, indicating that global intensity statistics are insufficient to capture local structural variations in complex images. Local fitting strategies yield improvements, with GWLM performing better on BSDS and LMF achieving stronger outcomes on ADE20K and COCO. Nevertheless, the proposed morphological fitting consistently obtains the best performance on all three datasets. Compared with the strongest alternative fitting strategy, morphological fitting improves mIoU and mDSC by 1.4% and 1.8% on BSDS, 2.4% and 2.9% on ADE20K, and 2.7% and 3.1% on COCO, respectively. These results demonstrate that morphological fitting provides more stable regional information for contour evolution, especially under complex scene structures and heterogeneous grayscale distributions. We also visualize the data-driven term e MFJD using these image fitting algorithms, as shown in Figure 10. The GM variant generates coarse activation maps and fails to separate target regions from complex backgrounds, especially when the foreground shares similar grayscale statistics with surrounding regions. GWLM and LMF introduce local information and therefore suppress part of the irrelevant background responses, while their fitting maps remain sensitive to local grayscale fluctuations. In contrast, our morphological fitting produces sharper and more coherent responses around the target objects.

5.2. Alternative Formulations of the Energy Function

The data-driven term of MFJD-Seg is constructed using Jeffreys divergence, which provides a symmetric measure of the discrepancy between the original image and the morphological fitting images. To examine the robustness of this formulation, we conduct an ablation study by replacing Jeffreys divergence with L 2 squared difference and Kullback–Leibler (KL) Divergence while keeping all other components unchanged. As shown in Table 8, the choice of energy formulation has a clear impact on segmentation performance. The L 2 squared-difference variant obtains the lowest results across all datasets, suggesting that direct pixel-wise intensity penalization is insufficient to model the statistical discrepancy between the original image and the morphological fitting images. The KL-based formulation improves the performance by introducing a distribution-aware discrepancy measure, while its asymmetric nature may lead to biased contour evolution when the foreground and background exhibit complex grayscale variations. The proposed formulation based on Jeffreys divergence consistently achieves the best results on BSDS, ADE20K, and COCO. Figure 11 illustrates the changes in the intensity salience of the original image under the influence of these energy function formulations. The L 2 and KL formulations exhibit more dispersed magnitude distributions, indicating that their energy descriptions are more easily affected by raw grayscale variations and background textures. The JD formulation produces a structured distribution, where discriminative pixels are better separated from background pixels. This observation supports the conclusion that Jeffreys divergence provides a more stable and selective energy representation for contour evolution. Together with the results in Section 5.1, these findings confirm that morphological fitting and Jeffreys divergence play complementary roles to overcome the limitations of previous methods: the former provides coherent regional descriptors, while the latter supplies a stable and selective discrepancy measure.

5.3. Impact of the Energy Constraint Term

The energy constraint term is introduced to regulate the data-driven force and suppress local grayscale fluctuations. To evaluate its effectiveness, we compare the segmentation results of MFJD-Seg with and without the energy constraint term. The corresponding experimental results are reported in Table 9. It is clear that removing the energy constraint term consistently degrades the segmentation performance. This indicates that the energy constraint term effectively suppresses abnormal fluctuations in the data-driven term and stabilizes the contour evolution process.

5.4. Impact of Mean Filtering

Mean filtering is applied to smooth spurious geometric fluctuations of the contour in non-edge regions. We also conduct an ablation analysis to evaluate the model’s performance both with and without this smoothing module. The quantitative outcomes reported in Table 10 demonstrate that this component contributes substantially to the overall segmentation workflow. Figure 12 visualizes the effect of mean filtering. Without mean filtering, the final contour contains local irregularities, and the level set surface exhibits noticeable fluctuations. After applying mean filtering, the contour becomes smoother and more consistent with the target boundary, while the level set function presents a more regular surface. This comparison indicates that mean filtering improves the stability and smoothness of the segmentation process.

5.5. Parameter Sensitivity Analysis

Structuring element size ω . The parameter ω determines the neighborhood scale of the structuring element, which directly affects the extent to which morphological fitting captures local grayscale features and suppresses small-scale interference. We assess the performance of MFJD-Seg across a range of ω , and the results are shown in Table 11. MFJD-Seg achieves the best performance when ω = 15 across all datasets. Smaller values of ω limit the ability of morphological fitting to capture sufficient local structural information, while larger values may introduce excessive neighborhood smoothing and weaken fine boundary details. The results indicate that a moderate structuring element size provides a better balance between local feature extraction and interference suppression.
Mean filtering window size k . The parameter k controls the spatial range of the mean filtering operation, thereby determining the degree of smoothing applied to the level set function. As shown in Table 12, MFJD-Seg achieves the best overall performance when k = 7 . A smaller window provides insufficient smoothing, while an overly large window may adversely impair boundary details and weaken structural discrimination. It is also worth noting that k has a weaker impact on performance than ω , which is intuitive since the structuring element is directly involved in core feature extraction, whereas mean filtering serves as a conservative post-processing step.
Iteration step size Δ t . The parameter Δ t controls the update magnitude of the level set function at each iteration, thereby affecting the convergence speed and numerical stability. As shown in Table 13, the best results are obtained at Δ t = 0.1 . When Δ t is too small, the update of the level set function becomes conservative and limits convergence within the fixed iteration budget. In contrast, larger step sizes introduce radical contour evolution and may lead to over-segmentation. This confirms that Δ t = 0.1 provides a suitable update scale for accurate and stable segmentation.
Iteration number N . The parameter N specifies the maximum number of level set evolution iterations, which determines the extent to which the contour can approach a stable segmentation state. We evaluate the segmentation performance of MFJD-Seg under different values of N, as reported in Table 14. The results show that N = 50 yields the optimal performance across all three datasets. On the BSDS dataset, the model is relatively robust, with performance at N = 35 already closely approaching the peak. In contrast, ADE20K and COCO exhibit higher sensitivity to smaller N values, showing more noticeable performance drops at N = 35 , with COCO being the most sensitive. Notably, for all datasets, further increasing N to 60 and 70 leads to a performance plateau, where the metrics remain nearly identical to those at N = 50 , demonstrating clear contour convergence.

6. Conclusions

We present MFJD-Seg, an active contour segmentation method that combines morphological grayscale fitting with energy modeling based on Jeffreys divergence. By using grayscale erosion and dilation to construct fitting images, the proposed method captures local structural cues while reducing the influence of background interference and intensity inhomogeneity. Jeffreys divergence provides a symmetric discrepancy measure between the original image and the fitting images, enabling a more stable and discriminative data-driven energy term. The energy constraint term and mean filtering operation further improve the stability of level set evolution and suppress irregular fluctuations. Comprehensive experiments across BSDS, ADE20K, and COCO datasets, including both standard and noisy imaging conditions, consistently validate the superiority of MFJD-Seg over competitive ACM baselines in terms of segmentation accuracy, efficiency, and noise robustness. While deep learning methods heavily rely on abundant labeled data and substantial training resources, MFJD-Seg offers a compelling, training-free alternative that is suitable for small-sample, unlabeled, or resource-constrained scenarios where computational overhead is critical. In the future, we plan to extend MFJD-Seg to video segmentation and further improve performance across diverse imaging scenarios.

Author Contributions

Conceptualization, J.S., G.W. and F.Z.; methodology, J.S., G.W. and F.Z.; software, J.S. and F.Z.; validation, J.S.; investigation, F.Z.; visualization, J.S.; project administration, J.S.; supervision, G.W. and F.Z.; writing—original draft preparation, J.S.; writing—review and editing, F.Z. All authors have read and agreed to the published version of the manuscript.

Funding

This research was partially supported by the Jiangsu Provincial Engineering Research Center for Robotics and Intelligent Equipment under Grant KY202301007 and the Financial Support Program of “Qinglan Project” for Jiangsu Higher Education Institutions under Grant 202505000001.

Institutional Review Board Statement

Not applicable. This study does not involve humans or animals.

Informed Consent Statement

Not applicable. This study does not involve humans or animals.

Data Availability Statement

The original data presented in the study are openly available in BSDS at https://www2.eecs.berkeley.edu/Research/Projects/CS/vision/bsds/ (accessed on 15 May 2026), ADE20K at https://ade20k.csail.mit.edu/ (accessed on 8 May 2026), and COCO at https://cocodataset.org/#download (accessed on 8 May 2026).

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Pan, C.; He, Y.; Peng, J.; Zhang, Q.; Sui, W.; Zhang, Z. BAEFormer: Bi-Directional and Early Interaction Transformers for Bird’s Eye View Semantic Segmentation. In Proceedings of the 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2023; pp. 9590–9599. [Google Scholar]
  2. Čavojský, M.; Mikula, Š.; Gazda, J.; Bugár, G. Enhancing Autonomous Vehicle Segmentation with Compact UNET Models and Temporal Input Fusion. Eng. Proc. 2025, 113, 71. [Google Scholar] [CrossRef]
  3. Liu, C.; Qiao, Z.; Zhang, Q. An Active Contour Model with Local Variance Force Term and Its Efficient Minimization Solver for Multiphase Image Segmentation. SIAM J. Imaging Sci. 2023, 16, 144–168. [Google Scholar] [CrossRef]
  4. Liu, Z.; Zhou, Y.; Xu, Y.; Wang, Z. SimpleNet: A Simple Network for Image Anomaly Detection and Localization. In Proceedings of the 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2023; pp. 20402–20411. [Google Scholar]
  5. Lu, J.; Lee, S.H. Real-Time Defect Detection Model in Industrial Environment Based on Lightweight Deep Learning Network. Electronics 2023, 12, 4388. [Google Scholar] [CrossRef]
  6. Ma, J.; He, Y.; Li, F.; Han, L.; You, C.; Wang, B. Segment anything in medical images. Nat. Commun. 2024, 15, 654. [Google Scholar] [CrossRef] [PubMed]
  7. Li, W.; Zhu, M.; Xie, J. DC-TransDPANet: A Transformer-Based Framework Integrating Composite Attention and Polarized Attention for Medical Image Segmentation. Electronics 2025, 14, 1913. [Google Scholar]
  8. He, Y.; Guo, P.; Tang, Y.; Myronenko, A.; Nath, V.; Xu, Z.; Yang, D.; Zhao, C.; Simon, B.; Belue, M.; et al. VISTA3D: A Unified Segmentation Foundation Model For 3D Medical Imaging. In Proceedings of the 2025 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2025; pp. 20863–20873. [Google Scholar]
  9. Ma, Q.; Liu, H.; Jin, Y.; Liu, X. Multi-Scale Context Enhancement Network with Local–Global Synergy Modeling Strategy for Semantic Segmentation on Remote Sensing Images. Electronics 2025, 14, 2526. [Google Scholar]
  10. Lv, X.; Persello, C.; Li, W.; Huang, X.; Ming, D.; Stein, A. Deep Merge: Deep-Learning-Based Region Merging for Remote Sensing Image Segmentation. IEEE Trans. Geosci. Remote Sens. 2025, 63, 5614120. [Google Scholar]
  11. Li, Z.; Zhang, F.; Wang, G.; Weng, G.; Chen, Y. An active contour model based on Kullback–Leibler divergence and morphology for image segmentation with edge leakage. Signal Process. 2026, 238, 110143. [Google Scholar]
  12. Feng, H.; Zhou, K.; Zhou, W.; Yin, Y.; Deng, J.; Sun, Q.; Li, H. Recurrent Generic Contour-Based Instance Segmentation with Progressive Learning. IEEE Trans. Circuits Syst. Video Technol. 2024, 34, 7947–7961. [Google Scholar] [CrossRef]
  13. Chen, Y.; Zhang, F.; Wang, G.; Weng, G.; Fontanelli, D. An Active Contour Model Based on Fuzzy Superpixel Centers and Nonlinear Diffusion Filter for Instance Segmentation. IEEE Trans. Instrum. Meas. 2025, 74, 5035013. [Google Scholar] [CrossRef]
  14. Pan, X.; Wang, D. GC Snakes: An Efficient and Robust Segmentation Model for Hot Forging Images. Sensors 2024, 24, 4821. [Google Scholar] [CrossRef] [PubMed]
  15. Shi, M.; Hussain, I. Improved region-based active contour segmentation through divergence and convolution techniques. AIMS Math. 2025, 10, 654–671. [Google Scholar] [CrossRef]
  16. Bu, Q.; Dong, B.; Zhu, Z.; Ni, J. Active Contour Model Driven by Non-Local Feature Fitting Energy Function With Scalable Normalization. IEEE Trans. Image Process. 2025, 34, 4939–4954. [Google Scholar] [CrossRef] [PubMed]
  17. Osher, S.; Sethian, J.A. Fronts propagating with curvature-dependent speed: Algorithms based on Hamilton-Jacobi formulations. J. Comput. Phys. 1988, 79, 12–49. [Google Scholar] [CrossRef]
  18. Kass, M.; Witkin, A.; Terzopoulos, D. Snakes: Active contour models. Int. J. Comput. Vis. 1988, 1, 321–331. [Google Scholar] [CrossRef]
  19. Li, C.; Huang, R.; Ding, Z.; Gatenby, J.C.; Metaxas, D.N.; Gore, J.C. A Level Set Method for Image Segmentation in the Presence of Intensity Inhomogeneities With Application to MRI. IEEE Trans. Image Process. 2011, 20, 2007–2016. [Google Scholar] [CrossRef] [PubMed]
  20. Chan, T.; Vese, L. Active contours without edges. IEEE Trans. Image Process. 2001, 10, 266–277. [Google Scholar] [CrossRef] [PubMed]
  21. Li, C.; Kao, C.Y.; Gore, J.; Ding, Z. Minimization of Region-Scalable Fitting Energy for Image Segmentation. IEEE Trans. Image Process. 2008, 17, 1940–1949. [Google Scholar] [CrossRef] [PubMed]
  22. Deng, M.; Zhou, Z.; Liu, G. SDCos_ACLS: Active contours with local blocks similarity guided by co-saliency maps based on sparse decomposition. Signal Process. 2026, 238, 110200. [Google Scholar]
  23. Xu, C.; Prince, J. Snakes, shapes, and gradient vector flow. IEEE Trans. Image Process. 1998, 7, 359–369. [Google Scholar] [CrossRef] [PubMed]
  24. Li, C.; Xu, C.; Gui, C.; Fox, M.D. Distance Regularized Level Set Evolution and Its Application to Image Segmentation. IEEE Trans. Image Process. 2010, 19, 3243–3254. [Google Scholar] [CrossRef] [PubMed]
  25. Caselles, V.; Kimmel, R.; Sapiro, G. Geodesic Active Contours. Int. J. Comput. Vis. 1997, 22, 61–79. [Google Scholar] [CrossRef]
  26. Dong, B.; Zhu, Z.; Bu, Q.; Ni, J. Active contour model with improved second-order differential driven term. Signal Process. 2025, 226, 109667. [Google Scholar]
  27. Xu, H.; Liu, T.; Wang, G. Hybrid geodesic region-based active contours for image segmentation. Comput. Electr. Eng. 2014, 40, 858–869. [Google Scholar] [CrossRef]
  28. Zhang, W.; Wang, X.; You, W.; Chen, J.; Dai, P.; Zhang, P. RESLS: Region and Edge Synergetic Level Set Framework for Image Segmentation. IEEE Trans. Image Process. 2020, 29, 57–71. [Google Scholar] [PubMed]
  29. Wan, M.; Huang, Q.; Xu, Y.; Gu, G.; Chen, Q. Global and local multi-feature fusion-based active contour model for infrared image segmentation. Displays 2023, 78, 102452. [Google Scholar]
  30. Jiang, X.; Feng, C.; Han, T.; Wu, B.; Yang, Y. Active contour model combining frequency domain information for noisy vessel image segmentation. Pattern Recognit. 2026, 171, 112126. [Google Scholar]
  31. Sazak, Ç.; Nelson, C.J.; Obara, B. The multiscale bowler-hat transform for blood vessel enhancement in retinal images. Pattern Recognit. 2019, 88, 739–750. [Google Scholar] [CrossRef]
  32. Wu, H.; Souedet, N.; Jan, C.; Clouchoux, C.; Delzescaux, T. A general deep learning framework for neuron instance segmentation based on Efficient UNet and morphological post-processing. Comput. Biol. Med. 2022, 150, 106180. [Google Scholar] [CrossRef] [PubMed]
  33. Cherian, A.; Stanitsas, P.; Harandi, M.; Morellas, V.; Papanikolopoulos, N. Learning Discriminative αβ-Divergences for Positive Definite Matrices. In Proceedings of the 2017 IEEE International Conference on Computer Vision (ICCV); IEEE: Piscataway, NJ, USA, 2017; pp. 4280–4289. [Google Scholar]
  34. Tang, B.; Kay, S.; He, H. Toward Optimal Feature Selection in Naive Bayes for Text Categorization. IEEE Trans. Knowl. Data Eng. 2016, 28, 2508–2521. [Google Scholar] [CrossRef]
  35. Min, H.; Jia, W.; Zhao, Y.; Zuo, W.; Ling, H.; Luo, Y. LATE: A Level-Set Method Based on Local Approximation of Taylor Expansion for Segmenting Intensity Inhomogeneous Images. IEEE Trans. Image Process. 2018, 27, 5016–5031. [Google Scholar] [CrossRef] [PubMed]
  36. Cai, Q.; Qian, Y.; Zhou, S.; Li, J.; Yang, Y.H.; Wu, F.; Zhang, D. AVLSM: Adaptive Variational Level Set Model for Image Segmentation in the Presence of Severe Intensity Inhomogeneity and High Noise. IEEE Trans. Image Process. 2022, 31, 43–57. [Google Scholar] [PubMed]
  37. Li, Z.; Tang, S.; Sun, T.; Yang, F.; Ye, W.; Ding, W.; Huang, K. A convex level-set method with multiplicative-additive model for image segmentation. Appl. Math. Model. 2024, 132, 587–606. [Google Scholar]
  38. Martin, D.; Fowlkes, C.; Tal, D.; Malik, J. A database of human segmented natural images and its application to evaluating segmentation algorithms and measuring ecological statistics. In Proceedings of the Eighth IEEE International Conference on Computer Vision (ICCV); IEEE: Los Alamitos, CA, USA, 2001; Volume 2, pp. 416–423. [Google Scholar]
  39. Zhou, B.; Zhao, H.; Puig, X.; Fidler, S.; Barriuso, A.; Torralba, A. Scene Parsing through ADE20K Dataset. In Proceedings of the 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2017; pp. 5122–5130. [Google Scholar]
  40. Lin, T.Y.; Maire, M.; Belongie, S.; Hays, J.; Perona, P.; Ramanan, D.; Dollár, P.; Zitnick, C.L. Microsoft COCO: Common Objects in Context. In Computer Vision—ECCV 2014; Springer International Publishing: Cham, Switzerland, 2014; pp. 740–755. [Google Scholar]
  41. Chen, D.; Spencer, J.; Mirebeau, J.M.; Chen, K.; Shu, M.; Cohen, L.D. A Generalized Asymmetric Dual-Front Model for Active Contours and Image Segmentation. IEEE Trans. Image Process. 2021, 30, 5056–5071. [Google Scholar] [CrossRef] [PubMed]
  42. Xue, P.; Niu, S. A novel active contour model based on features for image segmentation. Pattern Recognit. 2024, 155, 110673. [Google Scholar] [CrossRef]
  43. Dong, B.; Weng, G.; Bu, Q.; Zhu, Z.; Ni, J. An active contour model based on shadow image and reflection edge for image segmentation. Expert Syst. Appl. 2024, 238, 122330. [Google Scholar]
  44. Xie, E.; Wang, W.; Yu, Z.; Anandkumar, A.; Alvarez, J.M.; Luo, P. SegFormer: Simple and Efficient Design for Semantic Segmentation with Transformers. In Proceedings of the Advances in Neural Information Processing Systems; Curran Associates, Inc.: Red Hook, NY, USA, 2021. [Google Scholar]
  45. Zhang, T.; Wei, S.; Ji, S. E2EC: An End-to-End Contour-based Method for High-Quality High-Speed Instance Segmentation. In Proceedings of the 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2022; pp. 4433–4442. [Google Scholar]
  46. Cai, H.; Li, J.; Hu, M.; Gan, C.; Han, S. EfficientViT: Lightweight Multi-Scale Attention for High-Resolution Dense Prediction. In Proceedings of the 2023 IEEE/CVF International Conference on Computer Vision (ICCV); IEEE: Piscataway, NJ, USA, 2023; pp. 17256–17267. [Google Scholar]
  47. Niu, D.; Wang, X.; Han, X.; Lian, L.; Herzig, R.; Darrell, T. Unsupervised Universal Image Segmentation. In Proceedings of the 2024 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR); IEEE: Piscataway, NJ, USA, 2024; pp. 22744–22754. [Google Scholar]
  48. Jiang, J.; He, X.; Zhu, X.; Wang, W.; Liu, J. CGViT: Cross-image GroupViT for zero-shot semantic segmentation. Pattern Recognit. 2025, 164, 111505. [Google Scholar]
  49. Kirillov, A.; Mintun, E.; Ravi, N.; Mao, H.; Rolland, C.; Gustafson, L.; Xiao, T.; Whitehead, S.; Berg, A.C.; Lo, W.Y.; et al. Segment Anything. In Proceedings of the 2023 IEEE/CVF International Conference on Computer Vision (ICCV); IEEE: Piscataway, NJ, USA, 2023; pp. 3992–4003. [Google Scholar]
  50. Gao, D.; Chen, C.; Zhou, Y.; Zhang, H.; Hu, X. TS-SAM: Two Small Steps for SAM, One Giant Leap for Abnormal detections. In Proceedings of the 2024 IEEE International Conference on Multimedia and Expo (ICME); IEEE: Piscataway, NJ, USA, 2024; pp. 1–6. [Google Scholar]
  51. Gao, D.; Zhou, Y.; Yan, H.; Chen, C.; Hu, X. COD-SAM: Camouflage object detection using SAM. Pattern Recognit. 2025, 168, 111826. [Google Scholar] [CrossRef]
  52. Zhang, K.; Song, H.; Zhang, L. Active contours driven by local image fitting energy. Pattern Recognit. 2010, 43, 1199–1206. [Google Scholar] [CrossRef]
Figure 1. Overall pipeline of the MFJD-Seg framework. Structuring elements are leveraged to apply morphological erosion and dilation, which capture fundamental features. The red arrow indicates the direction of motion of the sliding window. By computing Jeffreys divergence between the original image and its eroded and dilated counterparts, enhanced feature maps are derived. The integration of these two maps yields the final energy-driven map, which provides the iterative driving force for the contour. To ensure numerical stability, we employ regularization to smooth the level set and improve parameter robustness, complemented by mean filtering to eliminate redundant noise components.
Figure 1. Overall pipeline of the MFJD-Seg framework. Structuring elements are leveraged to apply morphological erosion and dilation, which capture fundamental features. The red arrow indicates the direction of motion of the sliding window. By computing Jeffreys divergence between the original image and its eroded and dilated counterparts, enhanced feature maps are derived. The integration of these two maps yields the final energy-driven map, which provides the iterative driving force for the contour. To ensure numerical stability, we employ regularization to smooth the level set and improve parameter robustness, complemented by mean filtering to eliminate redundant noise components.
Electronics 15 02972 g001
Figure 2. Visualization of different structuring element geometries. Row 1: eroded images. Row 2: dilated images.
Figure 2. Visualization of different structuring element geometries. Row 1: eroded images. Row 2: dilated images.
Electronics 15 02972 g002
Figure 3. Comparison of the standard Heaviside function and our smoothed approximation.
Figure 3. Comparison of the standard Heaviside function and our smoothed approximation.
Electronics 15 02972 g003
Figure 4. Comparison of e MFJD curves with and without the energy constraint.
Figure 4. Comparison of e MFJD curves with and without the energy constraint.
Electronics 15 02972 g004
Figure 5. Visualization of segmentation results for different ACMs.
Figure 5. Visualization of segmentation results for different ACMs.
Electronics 15 02972 g005
Figure 6. Visualization of segmentation results for different deep learning models and MFJD-Seg.
Figure 6. Visualization of segmentation results for different deep learning models and MFJD-Seg.
Electronics 15 02972 g006
Figure 7. Examples of segmentation results for images with Gaussian noise.
Figure 7. Examples of segmentation results for images with Gaussian noise.
Electronics 15 02972 g007
Figure 8. Examples of segmentation results for images with salt-and-pepper noise.
Figure 8. Examples of segmentation results for images with salt-and-pepper noise.
Electronics 15 02972 g008
Figure 9. Examples of segmentation results for images with Poisson noise.
Figure 9. Examples of segmentation results for images with Poisson noise.
Electronics 15 02972 g009
Figure 10. Visualization of e MFJD for different ACMs.
Figure 10. Visualization of e MFJD for different ACMs.
Electronics 15 02972 g010
Figure 11. Pixel-level scatter comparison of different energy function formulations. The gray, blue, and red scatter points are generated based on the L 2 squared difference, KL divergence, and Jeffreys divergence, respectively.
Figure 11. Pixel-level scatter comparison of different energy function formulations. The gray, blue, and red scatter points are generated based on the L 2 squared difference, KL divergence, and Jeffreys divergence, respectively.
Electronics 15 02972 g011
Figure 12. Qualitative comparison before and after applying mean filtering. Row 1: The 2D segmentation results. Row 2: The 3D level set functions. The yellow and red lines denote the segmentation results before and after filtering, respectively.
Figure 12. Qualitative comparison before and after applying mean filtering. Row 1: The 2D segmentation results. Row 2: The 3D level set functions. The yellow and red lines denote the segmentation results before and after filtering, respectively.
Electronics 15 02972 g012
Table 1. Results of the comparative experiment with ACMs. The best performance is highlighted in bold.
Table 1. Results of the comparative experiment with ACMs. The best performance is highlighted in bold.
MethodBSDSADE20KCOCO
mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑
GADF81.085.337.745.447.628.437.236.432.1
ACFDI81.385.438.541.444.429.538.637.634.7
FeaACM85.088.839.745.148.631.842.740.938.3
SIRE77.784.646.347.650.939.236.537.341.1
SDCos_ACLS82.487.342.447.350.034.441.339.037.4
MFJD-Seg (Ours)89.793.450.752.455.643.847.545.745.4
Table 2. Results of the comparative experiment with deep learning models. The best performance is highlighted in bold.
Table 2. Results of the comparative experiment with deep learning models. The best performance is highlighted in bold.
MethodBSDSADE20KCOCO
mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑
SegFormer83.187.844.846.249.935.041.739.938.7
U2Seg84.488.852.151.454.244.542.741.346.8
E2EC86.189.946.047.751.137.244.142.240.8
CGViT87.591.248.750.253.040.445.543.142.2
EfficientViT88.692.151.549.052.145.246.244.246.1
MFJD-Seg (Ours)89.793.450.752.455.643.847.545.745.4
Table 3. Results of the comparative experiment with segmentation foundation models. The best performance is highlighted in bold.
Table 3. Results of the comparative experiment with segmentation foundation models. The best performance is highlighted in bold.
MethodBSDSADE20KCOCO
mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑
SAM88.692.222.550.854.019.347.045.820.7
TS-SAM90.393.617.153.256.114.949.147.016.0
COD-SAM89.192.815.551.654.713.647.646.214.5
MFJD-Seg (Ours)89.793.450.752.455.643.847.545.745.4
Table 4. Comparison of algorithm complexity with ACMs. N denotes the maximum iteration number, P refers to the total number of pixels in the input image, and d represents the dimension of the feature maps generated during segmentation.
Table 4. Comparison of algorithm complexity with ACMs. N denotes the maximum iteration number, P refers to the total number of pixels in the input image, and d represents the dimension of the feature maps generated during segmentation.
MethodsTime ComplexitySpace Complexity
GADF O N · P log P O P
ACFDI O N · P log P O P
FeaACM O N · P · d O P · d
SIRE O N · P · d 2 O P
SDCos_ACLS O N · P · d 2 O P · d
MFJD-Seg O N · P O P
Table 5. Comparison of algorithm complexity with deep learning models.
Table 5. Comparison of algorithm complexity with deep learning models.
MethodParams (M)GPU Mem. (GB)GFLOPs (G)
SegFormer24.201.8262.41
U2Seg44.503.25180.64
E2EC38.722.24245.85
CGViT124.604.06255.77
EfficientViT24.301.2819.11
SAM636.005.853851.43
TS-SAM32.601.87124.56
COD-SAM647.206.233865.04
MFJD-Seg0N/A1.22
Table 6. Results of the noise segmentation experiment. The best performance is highlighted in bold.
Table 6. Results of the noise segmentation experiment. The best performance is highlighted in bold.
MethodBSDSADE20KCOCO
mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑mIoU↑mDSC↑FPS↑
Under Gaussian noise
GADF74.378.233.238.040.124.329.729.228.5
ACFDI74.278.833.833.737.525.631.130.831.0
FeaACM78.381.835.437.341.827.135.533.233.7
SIRE71.077.342.641.143.934.729.330.536.5
SDCos_ACLS74.780.538.340.042.330.734.131.233.1
MFJD-Seg (Ours)85.188.647.248.151.141.343.241.043.0
Under salt-and-pepper noise
GADF72.176.533.135.438.224.127.527.128.2
ACFDI71.877.233.531.235.325.129.128.630.4
FeaACM76.380.235.134.839.526.833.231.433.1
SIRE69.475.142.138.541.234.227.328.436.2
SDCos_ACLS72.578.938.137.640.230.431.829.532.5
MFJD-Seg (Ours)83.489.146.845.949.241.541.239.442.7
Under Poisson noise
GADF76.880.934.540.542.725.432.431.829.8
ACFDI77.281.235.236.239.826.833.833.132.2
FeaACM81.484.636.839.944.228.338.235.935.1
SIRE73.680.144.243.846.536.331.933.438.2
SDCos_ACLS77.583.239.942.745.132.136.934.234.6
MFJD-Seg (Ours)88.592.349.151.254.442.645.843.944.5
Table 7. Ablation results of different image fitting algorithms. The best performance is highlighted in bold.
Table 7. Ablation results of different image fitting algorithms. The best performance is highlighted in bold.
ModelBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
w/GM84.988.746.749.040.638.3
w/GWLM88.391.648.551.444.041.8
w/LMF86.790.450.052.744.842.6
w/MF (Ours)89.793.452.455.647.545.7
Table 8. Ablation results of different energy function formulations. The best performance is highlighted in bold.
Table 8. Ablation results of different energy function formulations. The best performance is highlighted in bold.
ModelBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
w/ L 2 83.487.045.549.340.639.2
w/KL86.390.149.152.043.942.1
w/JD (Ours)89.793.452.455.647.545.7
Table 9. Ablation results of the energy constraint term. The best performance is highlighted in bold.
Table 9. Ablation results of the energy constraint term. The best performance is highlighted in bold.
ModelBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
w/o energy constraint86.390.647.751.142.341.1
w/energy constraint89.793.452.455.647.545.7
Table 10. Ablation results of the mean filtering module. The best performance is highlighted in bold.
Table 10. Ablation results of the mean filtering module. The best performance is highlighted in bold.
ModelBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
w/o mean filtering87.891.551.053.045.244.4
w/mean filtering89.793.452.455.647.545.7
Table 11. Performance of MFJD-Seg under different ω . The best performance is highlighted in bold.
Table 11. Performance of MFJD-Seg under different ω . The best performance is highlighted in bold.
ω BSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
1087.189.647.749.942.441.7
1388.992.351.354.146.145.0
1589.793.452.455.647.545.7
1789.192.150.853.745.944.6
2086.489.047.049.342.041.1
Table 12. Performance of MFJD-Seg under different k. The best performance is highlighted in bold.
Table 12. Performance of MFJD-Seg under different k. The best performance is highlighted in bold.
kBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
387.590.949.151.443.942.6
589.392.751.754.746.645.3
789.793.452.455.647.545.7
989.092.551.454.346.345.1
1187.290.348.350.843.242.0
Table 13. Performance of MFJD-Seg under different Δ t . The best performance is highlighted in bold.
Table 13. Performance of MFJD-Seg under different Δ t . The best performance is highlighted in bold.
Δ t BSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
0.0286.689.446.949.641.541.0
0.0588.592.050.353.345.343.9
0.189.793.452.455.647.545.7
0.287.290.348.050.743.242.2
0.384.186.742.445.437.637.6
Table 14. Performance of MFJD-Seg under different N. The best performance is highlighted in bold.
Table 14. Performance of MFJD-Seg under different N. The best performance is highlighted in bold.
NBSDSADE20KCOCO
mIoU↑mDSC↑mIoU↑mDSC↑mIoU↑mDSC↑
2087.490.347.450.342.041.3
3588.592.250.753.644.942.6
5089.793.452.455.647.545.7
6089.393.352.355.547.445.6
7089.493.252.255.447.345.6
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Su, J.; Weng, G.; Zhang, F. MFJD-Seg: Morphological Fitting Meets Jeffreys Divergence for Efficient Active Contour Segmentation. Electronics 2026, 15, 2972. https://doi.org/10.3390/electronics15132972

AMA Style

Su J, Weng G, Zhang F. MFJD-Seg: Morphological Fitting Meets Jeffreys Divergence for Efficient Active Contour Segmentation. Electronics. 2026; 15(13):2972. https://doi.org/10.3390/electronics15132972

Chicago/Turabian Style

Su, Jian, Guirong Weng, and Fuzheng Zhang. 2026. "MFJD-Seg: Morphological Fitting Meets Jeffreys Divergence for Efficient Active Contour Segmentation" Electronics 15, no. 13: 2972. https://doi.org/10.3390/electronics15132972

APA Style

Su, J., Weng, G., & Zhang, F. (2026). MFJD-Seg: Morphological Fitting Meets Jeffreys Divergence for Efficient Active Contour Segmentation. Electronics, 15(13), 2972. https://doi.org/10.3390/electronics15132972

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop