J. Ocean Eng. Technol. Search

CLOSE


J. Ocean Eng. Technol. > Volume 40(2); 2026 > Article
Lee, Cho, Hwang, Shin, and Kang: Proposal and Applicability Assessment of a Computer Vision–Based Quantification Method for Seawater Behavior in Coastal Aquifers

Abstract

Complex interactions between seawater and freshwater govern intrusion and stabilization in coastal aquifers. Previous studies have primarily relied on interface-based analyses, limiting full-field spatial quantification of seawater distribution. This paper proposes a computer vision–based method for quantifying seawater behavior in laboratory sand tank experiments. Experimental videos were acquired under controlled hydraulic and lighting conditions, and an image analysis framework was established in Python using OpenCV, including preprocessing, red–green–blue (RGB) and hue–saturation–value (HSV) color-space analysis, threshold determination, binary segmentation, region extraction, area calculation, and temporal filtering. Rhodamine-B dye enabled robust segmentation, and the H channel provided the most reliable separation with reduced sensitivity to illumination variations. The extracted seawater area time series showed an initial rapid increase, a temporary decrease associated with interface readjustment, a gradual reintrusion stage, and eventual stabilization. A fourth-order Butterworth low-pass filter with a cutoff frequency of 0.001 Hz was applied to suppress the high-frequency noise and clarify the convergence toward seawater–freshwater pressure equilibrium. Stabilization was defined as the stage at which the one-hour-averaged relative area-change rate fell below 1%. These findings suggest that the proposed framework enables the non-intrusive, reproducible quantification of seawater behavior and provides a practical alternative to conventional interface-based methods.

1. Introduction

Global sea-level rise and the increasing frequency of extreme weather events driven by climate change have intensified the vulnerability of coastal infrastructure to seawater-related hazards. According to the IPCC (2021), with the global mean temperature increasing by approximately 1.0 °C relative to the pre-industrial period, future sea levels are projected to rise by up to 0.93 m. Complementing these long-term projections, recent studies based on satellite observations have confirmed that the rate of global mean sea-level rise over the past 30 years has accelerated by approximately a factor of two (Hamlington et al., 2024). Sea-level rise, when combined with drivers such as spring high tides and storm surges, substantially increases the likelihood of seawater intrusion into low-lying coastal settings. This vulnerability is particularly noticeable along the western coast of the Korean Peninsula, where the tidal range is extensive, and the coastal topographic gradient is gentle (Jang & Kim, 2009; Park et al., 2020).
Such seawater forcing is not limited to short-term surface damage; it can also lead to secondary impacts by promoting the salinization of freshwater resources within coastal aquifers through direct seawater entry into the subsurface. The disruption of pressure equilibrium between freshwater and saltwater drives seawater intrusion into coastal aquifers. Once salinization occurs, the natural recovery of the groundwater system becomes exceedingly difficult (Ferguson & Gleeson, 2012; Werner et al., 2013). Recent attention has also been directed toward the possibility of rapid salinization in the upper aquifer zone under episodic, high-intensity marine forcing, which may differ from the more widely discussed lateral intrusion processes (Cantelon et al., 2022).
A broad range of theoretical, experimental, and numerical studies has been conducted to elucidate the behavior of seawater intrusion in coastal aquifers. Early theoretical and analytical studies proposed methods for estimating the equilibrium position of the saltwater–freshwater interface based on the Ghyben–Herzberg relationship (Glover, 1959; Henry, 1959; Strack, 1976). Experimental studies investigated how the aquifer properties and hydraulic head differences across boundaries influence the formation and evolution of the seawater–freshwater interface (Goswami & Clement, 2007; Abarca & Clement, 2009; Lu et al., 2013; Lee et al., 2018). Numerical studies extended this understanding further using density-dependent groundwater flow models to quantify the effects of tidal fluctuations, sea-level rise, and inland boundary conditions on seawater intrusion (Ataie-Ashtiani et al., 1999; Lee et al., 2019a). These numerical approaches have helped improve the physical understanding of mechanisms of seawater intrusion (Lee et al., 2019b).
In Korea, related studies have been steadily reported, including experimental investigations on the formation and control characteristics of the freshwater–saltwater interface (Park et al., 2009; Suh et al., 2010), analyses of transient salinization behavior considering groundwater-level fluctuations (Badaruddin et al., 2015; Lee et al., 2017; Abdoulhalik & Ahmed, 2018), and coastal aquifer simulations using a Navier–Stokes solver coupled with a porous body model (Lee et al., 2015; Cho et al., 2025). Experimental validation is essential to confirm that simulated seawater–freshwater interactions accurately reflect the underlying physical processes and establish the applicability and credibility of these models. In particular, quantitative experimental data describing the changes in seawater distribution and the associated stabilization process within coastal aquifers can serve as essential benchmarks for model verification and calibration.
Despite these advances, the direct quantification of seawater intrusion behavior in coastal aquifers from experimental videos remains limited. Robinson et al. (2015) reported the applicability of automated image analysis to experimental investigations of saltwater intrusion in coastal aquifers. Robinson et al. (2016) applied this approach to homogeneous aquifers, enabling a quantitative evaluation of the saltwater distribution under controlled laboratory conditions. Robinson et al. (2018) advanced this line of research by proposing an improved calibration method for image analysis in laboratory-scale seawater intrusion problems. Etsias et al. (2020) extended the framework by incorporating machine-learning techniques to estimate the saltwater concentration fields from image-derived light-intensity information. These studies highlight the potential of image-based analysis for quantitatively evaluating the saline behavior. Nevertheless, reproducible video-based quantification of seawater regions in coastal aquifer experiments remains limited under practical imaging conditions. In particular, illumination variability, low color contrast, and interface ambiguity caused by mixing-zone diffusion can reduce the robustness and consistency of video-based quantification. In addition, many studies have focused on concentration estimation under specific calibration settings or on interface-position analysis at selected time instants, which limits the systematic quantification of the continuous temporal evolution and stabilization of seawater regions from full video records.
From this perspective, a computer vision–based analysis framework that integrates color-space transformation, threshold selection, and region extraction is needed to robustly quantify the spatiotemporal evolution of seawater distribution across the entire experimental video record. In addition, the applicability of video-based quantitative analysis in hydraulic experiments has been shown in related contexts. For example, Kim et al. (2023) quantified the kinematics of rapidly drifting objects under a tsunami-like bore using Open-Source Computer Vision (OpenCV)-based red-green-blue (RGB) image-processing techniques.
Building on these developments, this study developed a computer vision–based video analysis method to quantify the seawater behavior in a coastal aquifer using sand-tank experiments and evaluated its applicability. A simplified seawater–freshwater interaction system behind an impermeable vertical revetment was reproduced, and an image analysis framework was established in Python using OpenCV, including video preprocessing, color-space transformation, binarization, and region extraction. This study established and validated a video-based framework to address the spatial limitations of conventional interface-based analyses by quantitatively tracking spatiotemporal variations in seawater distribution from experimental videos.

2. Laboratory Experiments

In this study, sand tank experiments were conducted to simulate the seawater intrusion process in a coastal aquifer until a pressure equilibrium between seawater and freshwater (hereafter referred to as the steady state) was established. Experimental videos were recorded throughout this process for subsequent image-based analysis. The experiments were conducted under a constant head difference between seawater and freshwater to observe seawater penetration into a freshwater-saturated coastal aquifer until a steady state was reached.
The hydraulic experiments were designed to provide baseline experimental data for quantitative tracking of seawater behavior within the coastal aquifer through video analysis, rather than to resolve the mechanism of seawater intrusion analytically.

2.1 Sand Tank for Seawater Intrusion Experiments

A two-dimensional (2D) sand tank system was used with dimensions of 1.8 m (L) × 0.55 m (H) × 0.2 m (W) to simulate the seawater intrusion process, as illustrated in the configuration shown in Fig. 1. The tank was uniformly filled with silica sand to a height of 0.45 m from the base to represent a simplified coastal aquifer. At the boundary between the seaward and landward sections, an impermeable vertical revetment with a thickness of 3 mm was installed at an embedment depth of 0.2 m, dividing the tank into seaward and landward compartments.
The total length of the landward compartment was 1.5 m. Auxiliary chambers, each 0.15 m in length, were installed at both ends of this compartment and separated from the aquifer by 20-mesh stainless steel screens. The screens facilitated unimpeded water passage while effectively retaining sand particles to prevent their migration from the aquifer into the auxiliary chambers. These chambers functioned as controlled reservoirs that supplied seawater and freshwater during the experiment, maintaining stable hydraulic head conditions within the aquifer.
Excessive water-level rise during testing was prevented by installing overflow control devices at both ends of the tank to induce natural overflow when the seaward water level and the groundwater level exceeded 0.40 m and 0.41 m, respectively. Throughout the experiments, seawater and freshwater were continuously supplied from external storage tanks to maintain the prescribed boundary water levels in the seaward and landward compartments. The experimental setup was designed to minimize temporal fluctuations and ensure stable boundary head conditions, allowing the system to reach a steady state between seawater and freshwater.

2.2 Imaging Conditions and Video Acquisition

Experimental videos were recorded with a digital video camera (Canon XA45) to track seawater behavior visually within the coastal aquifer. Table 1 lists the key specifications of the imaging system. The camera, equipped with a 1/2.3-inch CMOS sensor, provided stable, high-resolution imaging during long-duration recording, enabling continuous documentation of the entire experimental process. Seawater intrusion evolves gradually over time. Therefore, video frames were extracted at 1 frame per second (1 fps) to capture the progression of seawater behavior. Videos were recorded at 4K UHD resolution (3840 × 2160 pixels), allowing a clear identification of the seawater distribution and interface morphology within the sand aquifer.
The illumination conditions were maintained consistently throughout the experiments to ensure the reliability of color-based image analysis. A light-emitting diode (LED) panel with a color rendering index (CRI) of 90 or higher was used, and the correlated color temperature was set to approximately 5600 K, equivalent to daylight. Two lighting units were installed symmetrically at approximately 2 m from the tank, oriented toward its front face at an incidence angle of approximately 30°. This configuration minimized direct surface reflection and shadow formation while promoting spatially uniform color recording within the sand aquifer. The illuminance at the front surface of the tank was maintained at approximately 870 lux per lighting unit, and simultaneous illumination from both units produced temporally stable, spatially uniform lighting conditions across the experimental domain. The lighting output was fixed during the experiments to prevent fluctuations in illuminance, suppressing artificial variations in RGB and hue-saturation-value (HSV) color values induced by lighting instability.
The addition of Rhodamine-B dye to seawater facilitated distinct color-based separation, enabling precise visual tracking of the migration pathway and distribution within the recorded images. The camera was fixed in position in front of the tank to ensure the entire tank domain was included in the field of view, and the camera position and recording conditions were kept constant throughout the experiment. The acquired video data were then processed using RGB-and HSV-based image analysis techniques to quantify the spatiotemporal evolution of the seawater distribution within the coastal aquifer.

2.3 Experimental Materials

The coastal aquifer in the sand tank was formed using high-purity silica sand (>95%) corresponding to South Korean standard sand No. 6 in accordance with KS F2502 and KS F2526. Prior to use, the sand was oven-dried at 110 ± 5 °C for more than 24 h. Sieve analysis, specific gravity testing, pore structure evaluation, and constant-head permeability testing were conducted to characterize the porous medium. The grain-size distribution was determined by sieve analysis in accordance with ASTM D6913-17 (ASTM International, 2017). Table 2 lists the measured grain-size characteristics. The sand had a mean grain size of 0.97 mm and was classified as SP under the Unified Soil Classification System, indicating poorly graded sand. The specific gravity of the sand particles was measured using the water pycnometer method in accordance with ASTM D854-14 (ASTM International, 2014). The measured specific gravity was 2.61 (Table 2). The pore structure characteristics of the sand were evaluated from the dry unit weight and the specific gravity. Based on these measurements, the unit weight, void ratio, and porosity were determined to be 1.52 g/cm3, 0.72, and 0.42, respectively, as listed in Table 2. A constant-head permeability test was performed to determine the hydraulic conductivity of the sand in accordance with ASTM D2434-19 (ASTM International, 2019). The measured permeability coefficient was 0.065 cm/s, as listed in Table 2. These properties indicate that the material provided a simplified yet hydraulically meaningful representation of coarse-grained sandy soil in coastal aquifers and was appropriate for representing a simplified coastal aquifer in the laboratory experiments conducted in this study.
The freshwater used in the experiments was tap water, whereas seawater was prepared by dissolving refined salt to achieve the target salinity. The salinity and temperature of both fluids were measured using a Salt 6+ Handheld Meter. The resulting physical properties are summarized in Table 3. The freshwater and seawater had salinities of 0 and 33 psu, temperatures of 10.63 and 12.26 °C, and densities of 0.9996 and 1.0266 g/cm3, respectively. Accordingly, the density contrast between the two fluids was 0.027 g/cm3, which served as the principal driving factor governing the density-dependent interaction between seawater and freshwater in the coastal aquifer model.

3. Experimental Video Analysis Framework

This section presents the computer vision–based video analysis framework used in this study to quantify the seawater behavior using experimental images obtained from the coastal aquifer model. Video analysis was conducted in Python 3.13.0 using OpenCV 4.12.0.88. OpenCV was used as the primary platform for image preprocessing, color-space transformation, and segmentation (Bradski, 2000). The workflow comprised preprocessing procedures, including distortion correction and geometric alignment, followed by color-space transformation and image segmentation to extract the spatial distribution of seawater. These procedures were designed to mitigate the optical aberrations and geometric inconsistencies inherent in experimental recordings, enabling reliable discrimination between seawater and freshwater regions.

3.1 Preprocessing

A preprocessing pipeline comprising camera calibration, lens distortion correction, and homography-based rectification was implemented to achieve high spatial accuracy in quantitative image-based analysis. Optical distortions can misrepresent the spatial position, area, and boundary morphology of the seawater distribution, reducing the analytical accuracy. In this study, these preprocessing procedures were applied to the experimental images to ensure the reliability of subsequent segmentation and quantification processes.

3.1.1 Camera calibration and distortion correction

Camera calibration establishes the geometric relationship between three-dimensional (3D) world coordinates and 2D image coordinates by estimating the intrinsic and extrinsic camera parameters.
Under the conventional pinhole camera model, the relationship between a 3D point (X, Y, Z) in the world coordinate system, and its corresponding image coordinates (x′, y′) can be expressed as
(1)
s[x′y′1]=[fx0cx0fycy001] [RT][XYZ1]
where s is a scaling factor fx and fy denote the focal lengths expressed in pixel units, and cx and cy represent the coordinates of the principal point. R is a 3×3 rotation matrix, and T is a 3×1 translation vector. The variables X, Y, and Z denote the 3D coordinates in the experimental world system. The estimated parameters provide the fundamental geometric information required for subsequent distortion correction and alignment.

3.1.2 Lens distortion correction

Lens distortion, arising from the optical characteristics of camera lenses, causes straight lines in a scene to appear curved in the image, degrading the accuracy of quantitative image analysis. Distortion typically manifests as barrel distortion, pincushion distortion, or a combination of both. In particular, radial distortion becomes pronounced when wide-angle lenses are used and must be corrected for reliable image-based quantification. Lens distortion is generally decomposed into radial distortion and tangential distortion. Radial distortion increases with the distance from the image center, whereas tangential distortion arises from imperfect alignment between the lens and the image sensor. In this study, lens distortion was corrected using distortion coefficients estimated during camera calibration (Zhang, 2000).
Considering radial and tangential distortion, the coordinate transformation can be expressed as
(2)
{xdistorted=x(1+k1r2+k2r4+k3r6)+2p1xy+p2(r2+2x2)ydistorted=y(1+k1r2+k2r4+k3r6)+p1(r2+2y2)+2p2xy
where x and y denote undistorted normalized image coordinates, and xdistorted and ydistorted represent the corresponding distorted image coordinates. The radial coordinate from the image center is defined as r=x2+y2. The coefficients k1, k2, and k3 are the radial distortion coefficients, and p1 and p2 are the tangential distortion coefficients.

3.1.3 Geometric rectification

Even after lens distortion correction, residual geometric distortion may persist due to the camera viewing angle or installation misalignment. Geometric rectification restores linearity and spatial consistency within the image coordinate system by compensating for such distortions. In this study, a homography matrix was applied to geometrically transform the images with respect to the experimental tank plane (Hartley & Zisserman, 2003). The homography transformation is expressed as
(3)
[x′y′1]=H[xy1]
where x and y denote image coordinates before rectification, and x′ and y′ represent the geometrically rectified image coordinates. H is a 3×3 homography matrix estimated to preserve the spatial relationships on the experimental tank plane.

3.1.4 Preprocessing workflow

Fig. 2 shows the image preprocessing workflow used in this study. The procedure began with the acquisition of raw experimental images and checkerboard images for camera calibration. Using the checkerboard images, the intrinsic parameters and distortion coefficients were estimated using the checkerboard-based calibration method reported by Zhang (2000), as implemented in OpenCV. For parameter estimation, multiple images of a checkerboard pattern printed on A4 paper, with 9 × 6 inner corners and a square size of 20 mm, were acquired under fixed imaging conditions. The estimated calibration parameters were then applied to correct lens distortion in the raw experimental images. After lens distortion correction, geometric alignment and rectification were performed to ensure spatial consistency among the recorded images. The corrected images were then used for color-space analysis. This preprocessing workflow was used to minimize any geometric distortion and improve the reliability of the quantitative evaluation of seawater distribution.

3.2 Image Analysis Framework

Color-based image analysis was applied to the preprocessed experimental images to extract the distribution of seawater within the coastal aquifer model. The seawater was dyed with Rhodamine-B. Hence, a clear chromatic contrast was established between the seawater and freshwater regions. Consequently, pixel-level color information provides an effective basis for identifying the seawater distribution through sequential image analysis.
Digital color images represent each pixel as a combination of multiple color channels, most commonly stored in the RGB color space (Russ, 2006; Gonzalez & Woods, 2018). Although RGB provides an intuitive structure for image acquisition and storage, it remains sensitive to fluctuations in illumination and luminance. In controlled laboratory environments, even minor lighting fluctuations can compromise the stability of color-based segmentation when relying solely on RGB channels.
This limitation was mitigated using the HSV color space to separate chromatic information from the intensity channels. By decomposing color into H, S, and V channels, HSV reduces the influence of brightness variations and enables more robust discrimination between seawater and freshwater regions. Owing to these characteristics, HSV has been widely adopted for color-based object detection and segmentation (Burdescu et al., 2009; Cucchiara et al., 2001; Kang et al., 2021). The extraction of RGB and HSV information from digital images constitutes a fundamental step in color-based analysis, object segmentation, and color space transformation (Umbaugh, 2010).

3.2.1 RGB and HSV color models

The RGB color space (Fig. 3(a)) is the most fundamental representation of color in digital imaging, where the R, G, and B channels describe each pixel. In RGB, however, chromatic and intensity information are inherently coupled within each channel, making the representation sensitive to illumination changes and potentially reducing segmentation stability under varying lighting conditions. The HSV color space (Fig. 3(b)) was used in parallel to address this limitation. HSV separates H, S, and V into independent channels, minimizing the influence of brightness variations and enabling more stable color-based analysis centered on chromatic attributes. This separation enhances the robustness in detecting dyed seawater regions within the experimental aquifer images. The transformation from RGB to HSV is performed using normalized RGB values. The experimental images used in this study were standard 8-bit color images, in which the R, G, and B channels of each pixel are represented as integers in the range 0–255. Each RGB channel was normalized to the unitless range of [0, 1] to provide standardized input for the subsequent HSV transformation:
(4)
R′=R255,G′=G255,B′=B255
From the normalized RGB values, the maximum and minimum channel values are determined as follows:
(5)
{Cmax=max(R′,G′,B′)Cmin=min(R′,G′,B′)
Moreover, their difference is defined as
(6)
ΔC=Cmax-Cmin
The V channel is defined as
(7)
V=Cmax
The S channel is defined as
(8)
S={0:Cmax=0ΔCCmax:Cmax≠0
The H channel was calculated according to the dominant normalized RGB components:
(9)
H={60°×G′-B′ΔC:Cmax=R′60°×(2+B′-R′ΔC):Cmax=G′60°×(4+R′-G′ΔC):Cmax=B′
If the calculated H value is negative, it is adjusted by adding 360°:
(10)
H=H+360° (if H<0)

3.2.2 Image analysis procedure

In this study, a stepwise image analysis procedure was applied to quantify the seawater behavior within the coastal aquifer model using experimental videos, covering the workflow from image acquisition to area estimation. The integrated framework, implemented in Python using the OpenCV library, comprised image acquisition, preprocessing, chromatic conversion, threshold-based binarization, region-of-interest (ROI) extraction, and calculation of the quantitative indices, as shown in Fig. 4.
Preprocessing, including camera calibration and lens distortion correction, was performed after acquiring experimental videos using a digital camera–lens system. From the preprocessed images, pixel-wise RGB values were extracted, and an RGB-to-HSV color space conversion was performed to separate chromatic information from the intensity. In the HSV color space, the color distribution of dyed seawater was analyzed to determine the threshold ranges for identifying the seawater region. The defined thresholds were then applied to binarize the images and segment the seawater diffusion region.
The ROI was then extracted from the segmented seawater region, and spatial calibration was applied to convert the image coordinates to real-world lengths. This procedure enabled quantitative estimation of the area of the seawater diffusion region and associated geometric ratios. The same procedure was applied to all frames, allowing continuous tracking of the temporal variations in seawater distribution and diffusion behavior. Table 4 provides a detailed description of each step and its purpose.

4. Applicability Assessment Using Experimental Video

4.1 Image Preprocessing and Threshold Determination

The threshold values were determined by analyzing the color distributions in the RGB and HSV spaces to distinguish dyed seawater from freshwater within the coastal aquifer model. The thresholdselection procedure is presented using a representative video frame and the corresponding color distributions of selected regions.
Fig. 5 presents a representative frame from the experimental video recorded using the Canon XA45. Fig. 5(a) shows the original image, whereas Fig. 5(b) shows the preprocessed image, in which the chromatic contrast between seawater and freshwater was enhanced through camera correction, contrast enhancement, and noise reduction. This preprocessing improved the clarity of the color information required for threshold-based classification.
Fig. 6 shows the RGB color distributions extracted from the seawater and freshwater regions indicated by the dashed rectangles in Fig. 5(b). The selected regions have identical dimensions of 337 × 52 pixels (17,524 pixels). A comparison of the channel distributions indicated that the G channel provided relatively clear local separation because the dyed seawater and freshwater occupied distinct green-channel intensity ranges under the present experimental conditions. On the other hand, RGB channels remain sensitive to changes in illumination and overall brightness because they are defined directly by component intensities.
Fig. 7 shows the HSV color distributions of the same regions. Among the HSV channels, H and S showed clear separation between seawater and freshwater, whereas V showed partial overlap. H exhibited no overlap, indicating that hue-based thresholding was highly effective under the present imaging conditions, while the separation in S reflected the differences in chromatic purity between the two regions. The superior robustness of H was attributed to its relative insensitivity to illumination intensity, enabling stable segmentation throughout the long-duration experiment.
Table 5 lists the range of values for each RGB and HSV channel. In this study, H is expressed in degrees on a 0–360° scale, consistent with the adopted HSV definition. The term “N/A” in the overlapping column denotes the absence of overlap between the seawater and freshwater distributions under the present experimental conditions. The results suggest that the G channel in RGB and the H and S channels in HSV provided the primary discriminatory information for distinguishing seawater from freshwater. In contrast, the V channel showed partial overlap, suggesting that brightness alone was insufficient for reliable classification. The thresholds were defined based on the separated distribution ranges of these channels to ensure stable classification throughout the experimental video. This strategy supported quantitative tracking of seawater intrusion and subsequent recovery within the coastal aquifer model. To define the steady state objectively, a convergence criterion based on the changes in seawater area was introduced. Among the evaluated channels, the H channel provided the greatest discriminatory power under the present imaging conditions, separating the two distributions while remaining less affected by intensity variation than the RGB channels.

4.2 Region Extraction and Area Calculation

The quantitatively corrected image shown in Fig. 5(b), after camera calibration, contrast adjustment, and noise reduction, was used to estimate the seawater region. Figs. 8 and 9 show the comprehensive RGB and HSV distributions extracted from this image.
Fig. 8 shows the RGB color distributions of the selected analysis region, where Figs. 8 (a)–(c) present the histograms of the R, G, and B channels, respectively. The RGB distribution analysis indicated that overlapping intervals remain, even though differences between seawater and freshwater regions are evident in some channels. Consequently, stable separation of the two regions cannot be achieved using a single RGB channel. Although the G channel showed relatively clear separation in the locally selected seawater and freshwater regions used for the preliminary threshold evaluation in Section 4.1, its distribution over the full analysis region in Fig. 8(b) exhibits substantial overlap between seawater and freshwater pixels. This suggests that the local separability of the G channel did not extend consistently to the full image domain. Hence, the G channel was considered informative but not sufficiently robust for full region extraction.
Fig. 9 presents the HSV color distributions for the same region, where Figs. 9 (a)–(c) correspond to the H, S, and V channels, respectively. The H channel shows clear separation between the seawater and freshwater distributions, with little to no overlap between the two. In contrast, although differences in the S and V channels exist, partial overlap persists. Therefore, these channels were more suitable as supplementary indicators. Compared to the RGB channels, the H channel provided more stable discrimination because its hue-based definition made it less sensitive to brightness variation across the image, thereby improving consistency in seawater region extraction. Accordingly, the H channel was adopted as the primary threshold variable in this study, whereas the S and V channels were used only as supplementary references.
Based on these observations, binary segmentation was performed using the H channel. A threshold value, denoted as Hthreshold, was defined as the midpoint between the upper bound of the freshwater H range and the lower bound of the seawater H range, as listed in Table 5. The binary image was generated according to
(11)
Bpixel(i,j)={1:H(i,j)>Hthreshold0:otherwise
where Bpixel(i, j) denotes the binarized value at pixel location (i, j), and H(i, j) represents the hue value at that location.
The binarization result identified the pixels corresponding to the seawater region (Fig. 10), where the black region spatially coincides with the extracted seawater region identified in Fig. 5. The total number of seawater pixels, Nseawater, is calculated as:
(12)
Nseawater=∑i=1imax∑j=1jmaxBpixel(i,j)
The pixel counts were converted into physical area by applying spatial calibration using the known reference dimensions of the experimental setup. Therefore, the physical area of the seawater region, Aseawater, is defined as
(13)
Aseawater=Nseawater×Δx×Δy
where Δx and Δy denote the horizontal and vertical pixel resolutions converted into real-world length units. Through this procedure, the temporal evolution of the seawater region within the coastal aquifer model can be quantitatively tracked.

4.3 Noise Reduction

The time series of the extracted seawater area may contain nonphysical fluctuations arising from the camera characteristics, experimental conditions, and image processing operations. Such high-frequency components may mask the underlying physical mechanisms because seawater intrusion and recovery in a coastal aquifer evolve gradually over time. Therefore, post-processing is essential to ensure reliable quantitative interpretation.
The experimental videos were recorded at 1 fps, and the resulting seawater-area time series was treated as a discrete signal with a sampling frequency of 1 Hz. Low-frequency components primarily governed seawater migration within the aquifer, whereas image-acquisition noise typically appeared at higher frequencies. These components were separated by applying a low-pass filter to the time series of the seawater area.
A Butterworth low-pass filter (Butterworth, 1930) was used because of its maximally flat passband and relatively small phase distortion, making it suitable for time-dependent analysis. Filtering was implemented using the SciPy library (Virtanen et al., 2020), and the transfer function is defined as
(14)
M(f)=11+(ffc)2n
where f denotes frequency; fc is the cutoff frequency, and n is the filter order. In this study, n = 4 and fc = 0.001 Hz were selected based on the characteristic time scale of the intrusion process.
The Butterworth low-pass filter effectively extracted the low-frequency trend associated with seawater migration, and the filtered time series was then used to quantify the temporal behavior.

4.4 Pressure Equilibration Process in a Coastal Aquifer

Fig. 11 shows the temporal evolution of the seawater area during the simultaneous supply of seawater and freshwater. The pink curve represents the original area extracted from image analysis, while the black curve denotes the filtered result obtained using the Butterworth low-pass filter. The points labeled (a)–(j) indicate representative stages, and Fig. 12 presents the corresponding experimental images.
During the initial stages (a)–(b), freshwater infiltrated the porous medium, generating a transient pressure imbalance that caused rapid seawater intrusion beneath the vertical revetment. At stage (c), discharge toward the seaward side began beneath the revetment as the aquifer became progressively saturated with freshwater, and the seawater area temporarily decreased because of interface readjustment. From stage (d) onward, a stable freshwater discharge pathway developed, and seawater gradually intruded landward under the prevailing pressure gradient. Between stages (d) and (h), the seawater area increased gradually. At stage (h), the area reached a maximum and then declined slightly before stabilizing.
During stages (i)–(j), the seawater and freshwater pressures approached equilibrium, and the seawater area remained almost constant, with no further systematic intrusion or discharge. Accordingly, a convergence criterion was introduced to define the steady-state condition objectively. This condition was considered satisfied when the time-averaged relative rate of change in the filtered seawater area over a duration window TD satisfied the following criterion:
(15)
1TD∫tt+TD|1AseawaterdAseawaterdt|dt<0.01
indicating that the seawater area varies by less than 1% on average over a one-hour interval (TD = 3600 s).

4.5 Applicability Assessment

This study examined the feasibility of quantifying seawater behavior in a coastal aquifer using a computer vision approach applied to sand tank experiments. The spatiotemporal evolution of seawater distribution was tracked using image data by systematically applying RGB and HSV analyses, threshold determination, binarization, and area calculation procedures for Rhodamine-B-dyed seawater.
The seawater area gradually increased and converged toward a stable value, reflecting the pressure equilibration process within the aquifer. Comparison between the raw and filtered signals suggested that the Butterworth low-pass filter effectively suppressed high-frequency fluctuations in the original time series, enabling more precise identification of long-term trends without altering the underlying physical behavior.
The RGB and HSV distribution analyses indicated that the H channel provided the highest separability between the seawater and freshwater regions among the evaluated channels. This characteristic reduced sensitivity to illumination variations and improved segmentation stability under controlled experimental conditions.
Although the proposed method leverages color contrast, potential uncertainties, such as non-uniform dye distribution or diffusion during extended experiments, necessitate rigorous control of the imaging parameters to ensure segmentation accuracy. In addition, inconsistent lighting or camera settings may reduce the robustness of the threshold. These limitations highlight the importance of controlled image acquisition and consistent preprocessing procedures.
Overall, these findings suggest that the proposed image analysis framework enables non-intrusive, continuous quantification of the seawater intrusion dynamics in laboratory-scale coastal aquifer models. This framework provides a practical methodological basis for experimental investigations conducted under controlled hydraulic conditions.

5. Conclusion

This study developed and assessed an image analysis framework implemented in Python using OpenCV for the quantitative analysis of seawater behavior in a coastal aquifer model based on experimental video records. An integrated processing pipeline was established, incorporating RGB and HSV chromatic analysis, threshold determination, and temporal signal post-processing. This framework was applied systematically to experimental data to evaluate its performance and applicability.
The image analysis results showed that seawater dyed with Rhodamine-B could be reliably distinguished from freshwater, with the H channel providing the highest separability and enabling continuous spatiotemporal tracking of seawater distribution using experimental images alone. This result underscores the feasibility of augmenting conventional interface-based analyses with area-based quantification.
The application of a Butterworth low-pass filter to the seawater area time series effectively suppressed high-frequency fluctuations arising from image acquisition and processing. The filtered signal more clearly captured the gradual convergence toward pressure equilibrium between seawater and freshwater, suggesting that the image-based quantitative results captured the fundamental characteristics of seawater–freshwater interaction without introducing processing artifacts.
In summary, these findings highlight the applicability of the proposed image analysis framework to the objective quantification of seawater behavior and pressure equilibration processes in laboratory coastal aquifer models. The approach provides a reproducible method under controlled experimental conditions and serves as a practical tool for image-based quantification in coastal aquifer studies and related hydraulic–geotechnical laboratory investigations.

Conflict of Interest

Woo-Dong Lee serves as an editorial board member of the Journal of Ocean Engineering and Technology. However, he was not involved in the decision-making process for publishing this article. Additionally, no potential conflicts of interest related to this article have been reported.

Funding

This work was supported by National Research Foundation of Korea (NRF) grants funded by the Korean Government (MSIT) (RS-2 024-00356327).

Fig. 1
Structural configuration of the sand tank used to simulate seawater intrusion in a coastal aquifer
ksoe-2026-011f1.jpg
Fig. 2
Schematic workflow of the image preprocessing procedure
ksoe-2026-011f2.jpg
Fig. 3
Schematic diagram of the color spaces used for image analysis (Source: SharkD, 2008; Wikimedia Commons, CC BY-SA 3.0).
ksoe-2026-011f3.jpg
Fig. 4
Flowchart of the image analysis procedure applied to experimental videos
ksoe-2026-011f4.jpg
Fig. 5
Representative frame extracted from the experimental video: (a) original image and (b) preprocessed image after camera calibration, distortion correction, contrast enhancement, and noise reduction
ksoe-2026-011f5.jpg
Fig. 6
RGB color distribution of the selected seawater and freshwater regions indicated in Fig. 5(b)
ksoe-2026-011f6.jpg
Fig. 7
HSV color distribution of the selected seawater and freshwater regions indicated in Fig. 5(b)
ksoe-2026-011f7.jpg
Fig. 8
RGB color distributions of the selected analysis region extracted from Fig. 5(b)
ksoe-2026-011f8.jpg
Fig. 9
HSV color distributions of the selected analysis region extracted from Fig. 5(b)
ksoe-2026-011f9.jpg
Fig. 10
Binary image of the seawater region extracted using the hue-based threshold Hthreshold
ksoe-2026-011f10.jpg
Fig. 11
Temporal evolution of the seawater area within the coastal aquifer during pressure equilibration between seawater and freshwater
ksoe-2026-011f11.jpg
Fig. 12
Sequential experimental images showing the evolution of the seawater–freshwater interface at representative stages (a)–(j) indicated in Fig. 11
ksoe-2026-011f12.jpg
Table 1
Key specifications of the imaging system used in the experiments
Item Specification
Camera model Canon XA45
Image sensor 1/2.3-inch CMOS
Effective resolution 3840 × 2160 (4K UHD)
Frame rate 29.97 fps
Lens Canon 20× optical zoom
Recording format MP4
Table 2
Physical properties of the silica sand representing the coastal aquifer
Property Value
Mean grain size (mm) 0.97
Specific gravity 2.61
Unit weight (g/cm3) 1.52
Void ratio 0.72
Porosity 0.42
Permeability coefficient (cm/s) 0.065
USCS1) classification SP2)

1) Unified Soil Classification System

2) Poorly graded sand

Table 3
Physical properties of freshwater and seawater used in the experiments
Water type Salinity (psu) Temperature (°C) Density (g/cm3)
Freshwater 0 10.63 0.9996
Seawater 33 12.26 1.0266
Table 4
Stepwise image analysis procedure applied to experimental videos
Step Process Description
1 Image acquisition
  • Experimental images are acquired using a fixed digital camera system to maintain stable viewing geometry and lighting conditions throughout the experiment.

2 Image preprocessing
  • Camera calibration, lens distortion correction, and geometric rectification are conducted to mitigate optical aberrations and geometric errors in the raw images.

3 RGB value extraction
  • Pixel-wise RGB values are extracted from the preprocessed images for subsequent color space conversion and analysis.

4 RGB-to-HSV conversion
  • RGB values are converted to the HSV color space to separate chromatic information from intensity and reduce sensitivity to brightness variations.

5 Color distribution analysis
  • HSV color distributions are analyzed to identify characteristic ranges specific to the dyed seawater region.

6 Threshold determination
  • Threshold ranges for H, S, and V are defined based on the analyzed color distributions to isolate seawater from freshwater regions accurately.

7 Image binarization
  • Binary images are generated using the defined thresholds to segment the seawater intrusion region from the background.

8 ROI extraction
  • The region of interest (ROI) corresponding to the seawater distribution is extracted for precise quantitative analysis.

9 Spatial calibration
  • Pixel coordinates are mapped to real-world dimensions using known reference dimensions of the experimental setup.

10 Quantification of results
  • The area of the segmented seawater region and associated geometric ratios are computed using spatially calibrated binary images.

11 Frame-by-frame analysis
  • The procedure is applied sequentially to all frames to quantify the temporal evolution of the seawater intrusion.

Table 5
Ranges of RGB and HSV values for the seawater and freshwater regions used for threshold determination
Color space Channel Range

Seawater Freshwater Overlapping
RGB R 121–164 107–136 121–136
G 0–44 108–137 N/A
B 23–92 70–100 70–92
HSV H 323–350 42–72 N/A
S 178–255 58–98 N/A
V 121–164 109–137 121–137

References

Abarca, E., & Clement, T. P. (2009). A novel approach for characterizing the mixing zone of a saltwater wedge. Geophysical Research Letters, 36(6), L06402. https://doi.org/10.1029/2008GL036995
crossref
Abdoulhalik, A., & Ahmed, A. A. (2018). Transient investigation of saltwater upconing in laboratory-scale coastal aquifer. Estuarine, Coastal and Shelf Science, 214, 149-160. https://doi.org/10.1016/j.ecss.2018.09.024
crossref
International, A. S. T. M. (2014). Standard test methods for specific gravity of soil solids by water pycnometer (ASTM D854-14).

International, A. S. T. M. (2017). Standard test methods for particle-size distribution (gradation) of soils using sieve analysis (ASTM D6913-17).

International, A. S. T. M. (2019). Standard test method for permeability of granular soils (constant head) (ASTM D2434-19).

Ataie-Ashtiani, B., Volker, R. E., & Lockington, D. A. (1999). Tidal effects on sea water intrusion in unconfined aquifers. Journal of Hydrology, 216(1–2), 17-31.
crossref
Badaruddin, S., Werner, A. D., & Morgan, L. K. (2015). Water table salinization due to seawater intrusion. Water Resources Research, 51(10), 8397-8408.
crossref pdf
Bradski, G. (2000). The OpenCV Library. Dr Dobb’s Journal: Software Tools for the Professional Programmer, 25(11), 120-123.

Burdescu, D. D., Brezovan, M., Ganea, E., & Stanescu, L. (2009). A new method for segmentation of images represented in a HSV color space. Advanced Concepts for Intelligent Vision Systems, 606-617 Springer.
crossref
Butterworth, S. (1930). On the theory of filter amplifiers. Experimental Wireless and the Wireless Engineer, 7, 536-541.

Cantelon, J. A., Guimond, J. A., Robinson, C. E., Michael, H. A., & Kurylyk, B. L. (2022). Vertical saltwater intrusion in coastal aquifers driven by episodic flooding: A review. Water Resources Research, 58(11), e2022WR032614. https://doi.org/10.1029/2022WR032614
crossref
Cho, S., Hwang, T., Shin, S., Kang, G., & Lee, W. D. (2025). Analysis of coastal groundwater salinization induced by coastal inundation using numerical wave tank based on porous body model. Journal of Coastal Disaster Prevention, 12(1), 49-59. https://doi.org/10.20481/kscdp.2025.12.1.49
crossref
Cucchiara, R., Grana, C., Piccardi, M., Prati, A., & Sirotti, S. (2001). Improving shadow suppression in moving object detection with HSV color information. Proceedings of the IEEE Intelligent Transportation Systems Conference (ITSC 2001) 334-339. https://doi.org/10.1109/ITSC.2001.948679
crossref
Etsias, G., Hamill, G. A., Benner, E. M., Águila, J. F., McDonnell, M. C., Flynn, R., & Ahmed, A. A. (2020). Optimizing laboratory investigations of saline intrusion by incorporating machine learning techniques. Water, 12(11), 2996. https://doi.org/10.3390/w12112996
crossref
Ferguson, G., & Gleeson, T. (2012). Vulnerability of coastal aquifers to groundwater use and climate change. Nature Climate Change, 2(5), 342-345. https://doi.org/10.1038/nclimate1413
crossref
Glover, R. E. (1959). The pattern of fresh-water flow in a coastal aquifer. Journal of Geophysical Research, 64(4), 457-459. https://doi.org/10.1029/JZ064i004p00457
crossref
Gonzalez, R. C., & Woods, R. E. (2018). Digital image processing. 4th ed Pearson Education.

Goswami, R. R., & Clement, T. P. (2007). Laboratory-scale investigation of saltwater intrusion dynamics. Water Resources Research, 43(4), W04418. https://doi.org/10.1029/2006WR005151
crossref
Hamlington, B. D., Bellas-Manley, A., Willis, J. K., Fournier, S., Vinogradova, N., Nerem, R. S., Piecuch, C. G., Thompson, P. R., & Kopp, R. (2024). The rate of global sea level rise doubled during the past three decades. Communications Earth & Environment, 5, 601. https://doi.org/10.1038/s43247-024-01761-5
crossref
Hartley, R., & Zisserman, A. (2003). Multiple view geometry in computer vision. 2nd ed Cambridge University Press.

Henry, H. R. (1959). Salt water intrusion into fresh water aquifers. Journal of Geophysical Research, 64(11), 1911-1919. https://doi.org/10.1029/JZ064i011p01911
crossref
IPCC. (2021). Climate Change 2021: The Physical Science Basis, Cambridge University Press.

Jang, D. H., & Kim, J. S. (2009). Vulnerability assessment under sea level rise based on climate change in Chungnam coastal area. Journal of the Korean Geomorphological Association, 16(2), 1-13.

Kang, H. C., Han, H. N., Bae, H. C., Kim, M. G., Son, J. Y., & Kim, Y. K. (2021). HSV color-space-based automated object localization for robot grasping without prior knowledge. Applied Sciences, 11(16), 7593.
crossref
Kim, T., Hwang, T., Baek, S., Hong, S., Kim, J., & Lee, W. D. (2023). Experimental investigations using computer vision for debris motion generated by solitary waves. Journal of Earthquake and Tsunami, 17(04), 2350016. https://doi.org/10.1142/S1793431123500161
crossref
Lee, W. D., Jeong, Y. H., & Hur, D. S. (2015). Numerical simulation on seawater intrusion in coastal aquifer using N–S solver based on porous body model. Journal of Korea Water Resources Association, 48(12), 1023-1035.
crossref
Lee, W. D., Jeong, Y. H., & Hur, D. S. (2017). Effects of wave action on seawater intrusion in coastal aquifer and mitigation strategies. Journal of Ocean Engineering and Technology, 31(1), 47-59. https://doi.org/10.5574/KSOE.2017.31.1.047
crossref
Lee, W. D., Jeong, Y. H., & Jeon, H. S. (2019b). Groundwater flow analysis in a coastal aquifer with the coexistence of seawater and freshwater by using a non-hydrostatic pressure model. Journal of Coastal Research, 91(SI), 121-125. https://doi.org/10.2112/SI91-025.1
crossref
Lee, W. D., Yoo, Y. J., Jeong, Y. M., & Hur, D. S. (2019a). Experimental and numerical analysis on hydraulic characteristics of coastal aquifers with seawall. Water, 11(11), 2343. https://doi.org/10.3390/w11112343
crossref
Lee, W. D., Yoo, Y. J., Jeong, Y. M., Jeong, Y. H., & Hur, D. S. (2018). Experimental investigation of the effects of revetments on seawater intrusion in coastal aquifers. Journal of Coastal Research, 85(SI), 441-445. https://doi.org/10.2112/SI85-089.1
crossref
Lu, C., Chen, Y., Zhang, C., & Luo, J. (2013). Steady-state freshwater–seawater mixing zone in stratified coastal aquifers. Journal of Hydrology, 505, 24-34. https://doi.org/10.1016/j.jhydrol.2013.09.017
crossref
Park, H. J., Kim, W. I., Ho, J. S., & Ahn, W. S. (2009). Experimental study to parameterize salt-wedge formations in coastal aquifers. Journal of Korea Water Resources Association, 42(11), 1005-1015. https://doi.org/10.3741/JKWRA.2009.42.11.1005
crossref
Park, Y., Jung, B., & Kim, R. (2020). Flood risk assessment for coastal cities considering sea level rise due to climate change. Journal of the Korean Society of Hazard Mitigation, 20(6), 323-332. https://doi.org/10.9798/KOSHAM.2020.20.6.323
crossref
Robinson, G., Ahmed, A. A., & Hamill, G. A. (2016). Experimental saltwater intrusion in coastal aquifers using automated image analysis: Applications to homogeneous aquifers. Journal of Hydrology, 538, 304-313. https://doi.org/10.1016/j.jhydrol.2016.04.017
crossref
Robinson, G., Hamill, G. A., & Ahmed, A. A. (2015). Automated image analysis for experimental investigations of salt water intrusion in coastal aquifers. Journal of Hydrology, 530, 350-360. https://doi.org/10.1016/j.jhydrol.2015.09.046
crossref
Robinson, G., Moutari, S., Ahmed, A. A., & Hamill, G. A. (2018). An advanced calibration method for image analysis in laboratory-scale seawater intrusion problems. Water Resources Management, 32, 3087-3102. https://doi.org/10.1007/s11269-018-1977-6
crossref
Russ, J. C. (2006). The image processing handbook. 5th ed CRC Press.

Shark, D. (2008). Color solid comparison hsl hsv rgb cone sphere cube cylinder [Image]. Wikimedia Commons. https://commons.wikimedia.org/wiki/File:Color_solid_comparison_hsl_hsv_rgb_cone_sphere_cube_cylinder.png

Strack, O. D. L. (1976). A single-potential solution for regional interface problems in coastal aquifers. Water Resources Research, 12(6), 1165-1174. https://doi.org/10.1029/WR012i006p01165
crossref
Suh, S. K., Oh, C. M., Kim, W. I., & Ho, J. S. (2010). Experimental study of freshwater discharge and saltwater intrusion control in coastal aquifer. Journal of the Korean Society of Hazard Mitigation, 10(5), 159-168.

Umbaugh, S. E. (2010). Digital image processing and analysis: Human and computer vision applications with CVIPtools. 2nd ed CRC Press.

Virtanen, P., Gommers, R., Oliphant, T. E., Haberland, M., Reddy, T., Cournapeau, D., Burovski, E., Peterson, P., Weckesser, W., Bright, J., van der Walt, S. J., Brett, M., Wilson, J., Millman, K. J., Mayorov, N., Nelson, A. R. J., Jones, E., Kern, R., Larson, E., & van Mulbregt, P. (2020). SciPy 1.0: Fundamental algorithms for scientific computing in Python. Nature Methods, 17(3), 261-272. https://doi.org/10.1038/s41592-019-0686-2
crossref pmid pmc
Werner, A. D., Bakker, M., Post, V. E. A., Vandenbohede, A., Lu, C., Ataie-Ashtiani, B., Simmons, C. T., & Barry, D. A. (2013). Seawater intrusion processes, investigation and management: Recent advances and future challenges. Advances in Water Resources, 51, 3-26. https://doi.org/10.1016/j.advwatres.2012.03.004
crossref
Zhang, Z. (2000). A flexible new technique for camera calibration. IEEE Transactions on Pattern Analysis and Machine Intelligence, 22(11), 1330-1334. https://doi.org/10.1109/34.888718
crossref
TOOLS
Share :
Facebook Twitter Linked In Google+ Line it
METRICS Graph View
  • 0 Crossref
  •   Scopus
  • 2,352 View
  • 24 Download


ABOUT
BROWSE ARTICLES
ARTICLE CATEGORY

Browse all articles >

PUBLICATION ETHICS
FOR CONTRIBUTORS
Editorial Office
President Office BD Rm. 1302, 13 Jungang-daero 180beon-gil, Dong-gu, Busan 48821, Republic of Korea
Tel: +82-51-759-0656    Fax: +82-51-759-0656    E-mail: ksoehj@ksoe.or.kr                

Copyright © 2026 by The Korean Society of Ocean Engineers.

Developed in M2PI

Close layer
prev next