Adaptive Contextual Embedding for Robust Far-View Borehole Detection

Xuesong Liu, Tianyu Hao, Emmett J. Ientilucci · 2025

Read Adaptive Contextual Embedding for Robust Far-View Borehole Detection by Xuesong Liu, Tianyu Hao, Emmett J. Ientilucci (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2505-05008.txt.

Introduction

Liu, Hao, and Ientilucci propose in 2025 a detection method for tiny blast holes seen from far away at quarry sites. Crews must spot densely packed boreholes in far view images for safe, efficient blasting. Small size, tight packing, and weak visual traits make that hard for standard detectors.

Built on a common detector base, their method keeps a running average of image statistics. That average drives adaptive image boosts, steadier feature extraction, and context based refinement of results. The moving average suits the low visual variety of boreholes. Tests on a private quarry dataset showed large gains over the baseline detector family.

Catalog record

CREATORXuesong Liu, Tianyu Hao, Emmett J. Ientilucci
YEAR2025
COLLECTIONPAPERS
FORMATTXT
FILE SIZE25 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2505-05008

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

Adaptive Contextual Embedding for Robust Far-View Borehole Detection Xuesong Liu, Tianyu Hao, Emmett J. Ientilucci Abstract In controlled blasting operations, accurately detecting densely distributed tiny boreholes from far-view imagery is critical for operational safety and efficiency. However, existing detection methods often struggle due to small object scales, highly dense arrangements, and limited distinctive visual features of boreholes. To address these challenges, we propose an adaptive detection approach that builds upon existing architectures (e.g., YOLO) by explicitly leveraging consistent embedding representations derived through exponential moving average (EMA)-based statistical updates. Our method introduces three synergistic components: (1) adaptive augmentation utilizing dynamically updated image statistics to robustly handle illumination and texture variations; (2) embedding stabilization to ensure consistent and reliable feature extraction; and (3) contextual refinement leveraging spatial context for improved detection accuracy. The pervasive use of EMA in our method is particularly advantageous given the limited visual complexity and small scale of boreholes, allowing stable and robust representation learning even under challenging visual conditions. Experiments on a challenging proprietary quarry-site dataset demonstrate substantial improvements over baseline YOLO-based architectures, highlighting our method’s effectiveness in realistic and complex industrial scenarios. 1 Introduction Rapid advancements in deep learning have significantly enhanced classical computer vision tasks such as image classification [ 14 , 11 ] , object detection [ 20 , 2 , 4 ] , and semantic segmentation [ 18 , 15 ] . Despite these advances, specialized industrial settings—especially for detecting tiny, densely packed objects—remain challenging and relatively unexplored. Industrial scenarios such as open-pit mining and quarry-site operations present unique visual complexities rarely seen in conventional detection datasets. Accurately identifying tiny boreholes used in controlled blasting requires robust handling of extremely small scales, dense object distributions, and substantial visual variability from textures, geological conditions, lighting, and environmental noise [ 27 , 10 ] . Standard detection methods frequently struggle under these conditions, causing elevated false alarms and missed targets, thus compromising operational efficiency and safety. Existing techniques addressing these challenges typically include contextual integration [ 6 ] , adaptive data augmentation [ 9 ] , and embedding-based feature consistency methods [ 23 ] . However, these approaches have mostly been studied independently or in simpler scenarios, leaving their combined potential in realistic industrial contexts under-investigated. To address these critical gaps, we propose an adaptive detection approach built upon established detection architectures (e.g., YOLO), specifically designed to detect densely distributed tiny boreholes reliably under complex quarry-site conditions. Our method leverages exponential moving averages (EMA) across multiple stages, ensuring robust learning given the small scale, dense distribution, and limited distinctive visual features of boreholes. Our key contributions include: • Adaptive Augmentation: Dynamically updates augmentation parameters using EMA-based global image statistics, explicitly mitigating variability caused by diverse illumination conditions, soil textures, and geological backgrounds frequently encountered in borehole imagery. • Embedding Stabilization: Employs EMA-driven embedding updates to maintain stable and consistent feature extraction, explicitly addressing challenges posed by the small scale, limited distinctive visual features, and high-density distributions of boreholes, thus reducing false alarms and improving detection reliability. • Contextual Refinement: Integrates spatial context embeddings refined via EMA to effectively distinguish true borehole targets from visually ambiguous environmental noise such as dust, debris, and surface irregularities typical in quarry-site imagery. Extensive experiments on a challenging proprietary quarry-site dataset demonstrate substantial improvements in detection accuracy and robustness when integrating our innovations into widely-adopted detection backbones such as YOLO-series [ 1 ] , RCNN-series [ 20 ] , and NanoDet [ 19 ] . Our approach thus advances both theoretical understanding and practical capabilities, significantly enhancing real-world operational effectiveness and safety. 2 Method We propose an adaptive detection method tailored for accurately detecting tiny, densely distributed boreholes in challenging industrial imagery. Given their small scale, dense arrangements, and limited distinctive features, we employ exponential moving average (EMA) techniques across our method to stabilize and enhance feature representations. As illustrated in Fig. 1 , our approach integrates three key EMA-supported components: (1) Adaptive Augmentation to handle illumination and background variability; (2) Embedding Stabilization for consistent and robust feature extraction; and (3) Contextual Refinement to leverage spatial context, effectively distinguishing boreholes from visually similar background noise. Figure 1 : Overview of our adaptive detection method illustrating integration points of Adaptive Augmentation (Sec. 2.1), Embedding Stabilization (Sec. 2.2), and Contextual Refinement (Sec. 2.3). 2.1 Adaptive Augmentation Adaptive augmentation dynamically enhances borehole visibility and mitigates background variability (e.g., illumination, textures) using exponential moving averages (EMA). At iteration t , local ( \mu_{\Omega}^{(t)},\sigma_{\Omega}^{(t)} ) and global ( \mu_{ref}^{(t)},\sigma_{ref}^{(t)} ) image statistics are computed: \displaystyle\mu_{\Omega}^{(t)} \displaystyle=\frac{1}{|\Omega|}\sum_{(u,v)\in\Omega}X^{(t)}(u,v), (1) \displaystyle\sigma_{\Omega}^{(t)} \displaystyle=\sqrt{\frac{1}{|\Omega|}\sum_{(u,v)\in\Omega}(X^{(t)}(u,v)-\mu_{\Omega}^{(t)})^{2}}, (2) \displaystyle\mu_{ref}^{(t)} \displaystyle=(1-\rho)\mu_{ref}^{(t-1)}+\rho\,\mu_{batch}^{(t)}, (3) \displaystyle\sigma_{ref}^{(t)} \displaystyle=(1-\rho)\sigma_{ref}^{(t-1)}+\rho\,\sigma_{batch}^{(t)}, (4) where \rho\in[0.01,0.1] is the EMA smoothing factor, typically chosen to ensure gradual and stable statistical updates. Augmentation parameters for brightness ( \alpha^{(t)} ), contrast ( \beta^{(t)} ), and additive noise ( \eta^{(t)} ) are adaptively derived as: \displaystyle\alpha^{(t)} \displaystyle=1+k_{1}\frac{\mu_{ref}^{(t)}-\mu_{\Omega}^{(t)}}{\mu_{ref}^{(t)}},\hskip 10.00002ptk_{1}\in[0.5,1.5], \displaystyle\beta^{(t)} \displaystyle=1+k_{2}\frac{\sigma_{ref}^{(t)}-\sigma_{\Omega}^{(t)}}{\sigma_{ref}^{(t)}},\hskip 10.00002ptk_{2}\in[0.5,1.5], \displaystyle\eta^{(t)} \displaystyle=k_{3}\frac{|\sigma_{ref}^{(t)}-\sigma_{\Omega}^{(t)}|}{\sigma_{ref}^{(t)}},\hskip 10.00002ptk_{3}\in[0.01,0.1]. (5) Here, the brightness ( \alpha^{(t)} ) and contrast ( \beta^{(t)} ) adjustments explicitly compensate for local deviations in illumination and texture compared to global references, enhancing feature consistency. The additive Gaussian noise ( \eta^{(t)} ) further enhances robustness against subtle background variations. The augmented image at iteration t is computed as: \displaystyle X^{\prime(t)}(u,v) \displaystyle=\beta^{(t)}\alpha^{(t)}X^{(t)}(u,v)+\eta^{(t)}\epsilon(u,v), (6) \displaystyle\epsilon(u,v) \displaystyle\sim\mathcal{N}(0,1). 2.2 Embedding Stabilization Embedding stabilization explicitly addresses embedding coherence challenges caused by small object scales, dense distributions, and limited visual distinctions among boreholes. At iteration t , embeddings e_{i}^{(t)} are first spatially grouped into embedding sets G_{j}^{(t)} based on spatial proximity: G_{j}^{(t)}=\{e_{i}^{(t)}\mid\|c_{i}-c_{j}\|_{2}<\delta\}, (7) where c_{i},c_{j} denote embedding spatial centers, and proximity threshold \delta\in[20,100] pixels determines local spatial coherence. We progressively refine cluster-level ( \mu_{j}^{(t)} ) and global ( \mu_{global}^{(t)} ) embedding representations using exponential moving averages (EMA): \displaystyle\mu_{j}^{(t)} \displaystyle=(1-\rho)\mu_{j}^{(t-1)}+\rho\frac{1}{|G_{j}^{(t)}|}\sum_{e\in G_{j}^{(t)}}e, (8) \displaystyle\mu_{global}^{(t)} \displaystyle=(1-\rho)\mu_{global}^{(t-1)}+\rho\frac{1}{N_{t}}\sum_{j}\sum_{e\in G_{j}^{(t)}}e, (9) where EMA smoothing factor \rho\in[0.01,0.1] ensures stable updates. Embedding consistency is enforced via two complementary losses: clustering consistency loss ( L_{cluster}^{(t)} ), ensuring spatial coherence of embeddings within each image, and stacking consistency loss ( L_{stack}^{(t)} ), enforcing temporal stability of embeddings across multiple images and training iterations: L_{cluster}^{(t)}=\frac{1}{J_{t}}\sum_{j=1}^{J_{t}}\left(\frac{1}{|G_{j}^{(t)}|}\sum_{e\in G_{j}^{(t)}}\|e-\mu_{j}^{(t)}\|_{2}^{2}+\lambda\|\mu_{j}^{(t)}-\mu_{global}^{(t)}\|_{2}^{2}\right), (10) L_{stack}^{(t)}=\frac{1}{|G_{j}^{(t)}|}\sum_{e\in G_{j}^{(t)}}\|e-e_{stack}^{(t)}\|_{2}^{2}, (11) where hyperparameter \lambda\in[0.5,2.0] balances local cluster and global embedding coherence. The stacked embedding representation ( e_{stack}^{(t)} ) aggregates embeddings temporally across training iterations: e_{stack}^{(t)}=(1-\rho)e_{stack}^{(t-1)}+\rho\frac{1}{|G_{j}^{(t)}|}\sum_{e\in G_{j}^{(t)}}e. (12) Thus, clustering consistency explicitly maintains spatial embedding coherence within each image, while stacking consistency explicitly ensures temporal embedding stability across image batches. 2.3 Contextual Refinement Contextual refinement leverages spatial information around candidate detections, exploiting the observation that boreholes typically share embedding characteristics regardless of local density. We expand original bounding boxes (x_{i},y_{i},w_{i},h_{i}) by a factor \gamma\in[0.1,0.5] to capture spatial context: \tilde{b}_{i}^{(t)}=(x_{i}-\gamma w_{i},\,y_{i}-\gamma h_{i},\,w_{i}+2\gamma w_{i},\,h_{i}+2\gamma h_{i}). (13) Contextual embeddings E_{context}^{(t)}(\tilde{b}_{i}) are extracted via ROI pooling from expanded bounding boxes and progressively refined using exponential moving averages (EMA): E_{context}^{ref(t)}=(1-\rho)E_{context}^{ref(t-1)}+\rho\frac{1}{N_{t}}\sum_{i=1}^{N_{t}}E_{context}^{(t)}(\tilde{b}_{i}), (14) where EMA smoothing \rho\in[0.01,0.1] ensures stable updates. We enforce consistency between the current contextual embeddings and their EMA-updated reference via a contextual consistency loss: L_{context}^{(t)}=\frac{1}{N_{t}}\sum_{i=1}^{N_{t}}\|E_{context}^{(t)}(\tilde{b}_{i})-E_{context}^{ref(t)}\|_{2}^{2}. (15) These refined contextual embeddings are then concatenated with object embeddings E_{object}^{(t)}(b_{i}) , forming combined embeddings: E_{merged}^{(t)}(b_{i})=\text{Concat}(E_{object}^{(t)}(b_{i}),E_{context}^{ref(t)}). (16) 2.4 Overall Objective Our adaptive detection approach integrates adaptive augmentation (Sec. 2.1), embedding stabilization (Sec. 2.2), and contextual refinement (Sec. 2.3) into standard detection architectures (e.g., YOLO). The total loss explicitly combines the standard detection losses with embedding and

Read the complete text