CS Paper Radar

TRUCO: A Scalable Lock-Free Algorithm for Parallel Contour Extraction

Rafael Munoz-Salinas, Francisco J. Romero-Ramirez, Manuel J. Marin-Jimenez

cs.CV ·submitted 2026-10-27 14:18 UTC · v2
theoryunusual

Abstract

Extracting closed pixel contours from a binary image, together with the hierarchy that records which contours enclose which, is a basic step in many computer vision pipelines, from fiducial marker detection to the vectorization of segmentation masks. The reference algorithm, by Suzuki and Abe, is inherently sequential: each contour is found by a raster scan that depends on the labels left by all previous contours, and its parent is obtained from the last contour met by the scan. This paper presents TRUCO (Threaded Raster Unrestricted Contour Ownership), a multi-core algorithm that returns exactly the output of Suzuki--Abe (the same contours, in the same order, with the same hierarchy) without locks, read-modify-write operations or a stitching phase. The method rests on two ideas. First, the image is divided into horizontal stripes, one per thread, and two rules, row-local writes and geometric contour ownership, let each thread trace complete contours independently of the others. Second, the tracing of the contours is separated from the computation of the hierarchy, which is recovered afterwards from one reference per contour; the trace therefore stores no contour numbers in the label image, which also makes it more efficient than that of the original algorithm when a single thread is used. We prove that the output is deterministic and identical to that of Suzuki--Abe, and that the algorithm is free of data races. Experiments on synthetic images, high-resolution photographs and segmentation masks, on a desktop and a server CPU, show that TRUCO scales with the number of threads and is several times faster than the fastest sequential methods, with and without the hierarchy. With a single thread, it is already faster than Suzuki--Abe.

Closest papers

Nearest neighbours by meaning across the whole index.

SweepLSD: A One-Pass, O(width)-Memory Line Segment Detector with an Integer-Only Streaming Core and a Real-Time FPGA Realization

eess.IV cs.ARcs.CV ·2026-08-22 ·Yoshiyasu Shimizu
code/data similarity 0.51
Abstract · 40 pages, 12 figures, 18 tables. Code, benchmarks, and evaluation harnesses (MIT): https://github.com/yosh-shimizu/sweeplsd

We present SweepLSD, a line segment detector that reads the image exactly once and emits each segment within a few rows of its last pixel passing the scan line. Every stage, including connected-component labeling and the final line test, processes the image as a row stream: intermediate memory is O(width) rather than O(pixels), and the per-pixel core is integer-only. We give the first complete description of the algorithm, designed in the author's 2014 master's thesis but never published, together with an open-source C++17 implementation and an FPGA realization -- held bit-exact against the software in its hardware configuration -- detecting segments in live 1080p30 video on 2009-era silicon without frame buffer or external memory. On structure-rich public 4K photographs downscaled to Full-HD, one CPU thread detects segments in ~11 ms -- 4.6x/5.2x/25x faster than the original authors' implementations of ELSED, EDLines, and LSD -- with the tightest frame-time distribution and the best per-segment direction accuracy of the four detectors, and curve rejection by design, while trailing ELSED in F-score on synthetic ground truth. A Manhattan-frame vanishing-point study on York Urban and NYU-VP scores every detector under a selection/evaluation-separated best-estimator-per-detector protocol, under which SweepLSD leads on NYU-VP by ~0.3 degrees and trails by 0.1 degrees on York Urban, with the fastest end-to-end pipeline of the four detectors on both. A single-frame camera-attitude application, evaluated on synthetic scenes with exact ground truth and on EuRoC and TUM-VI, matches the baselines' accuracy at a fraction of their memory, and drives a 4K horizon lock to 0.06 degrees median attitude error at 32 ms median per frame.

0.44

CuPH: Parallel Cubical Persistent Homology via Level-Synchronous Component Tracking

cs.CV cs.CGcs.DC ·2026-10-31 ·Guangyu Meng, Pengfei Gu, Erin Wolf Chambers, Danny Z. Chen
theory similarity 0.48
Abstract

Persistent homology (PH) is a mathematically principled multi-scale topological descriptor of shape and connectivity in data. It is widely applied in image classification, segmentation, and shape analysis across medical and aerial imaging, providing structural information that pixel-wise deep learning may overlook. Standard cubical PH decomposes an image into cubical cells (vertices, edges, and squares) and reduces them sequentially in filtration order. This sequential reduction has $Θ(n)$ parallel depth for an $n$-pixel image, limiting within-image GPU parallelism and constraining its use in topology-aware deep learning. We introduce CuPH, a GPU-based parallel algorithm for computing cubical PH on 2D images that operates directly on pixels rather than cubical cells. CuPH buckets pixels by filtration values, activates them with a level-synchronous sweep, and tracks connected components with a lock-free union-find method. We prove that CuPH produces persistence diagrams identical to standard cubical PH on integer inputs, with a stability bound for floating-point inputs. CuPH reduces parallel depth from $Θ(n)$ to $O(L\log n)$ for an image with $L$ intensity levels. We implement the level sweep as a single CUDA kernel, eliminating cross-level kernel-launch overhead. Empirically, CuPH is $18.6$--$99.6\times$ faster than the existing GPU baseline (CMP). As a drop-in PH backend, CuPH accelerates topology-aware classification ($4.2$--$16.7\times$) and segmentation ($8.3$--$44\times$) while preserving accuracy. It also enables computing full-image PH losses on high-resolution images, improving segmentation Dice by $2.2$--$4.6$ points over patch-local PH baselines and accelerating training by $25$--$31\times$.

0.14

Playing with Kruskal: algorithms for flat and hierarchical watershed cuts

cs.CV ·2026-10-07 ·Jean Cousty, Laurent Najman, Benjamin Perret, Deise Santana Maia
publishedunusual similarity 0.48
Abstract

In the framework of edge-weighted graphs, watersheds have proven to be linked to well-known optimization problems, as Minimum Spanning Tree, which allowed the design of efficient algorithms for computing (hierarchical) watershed segmentations. In the present article, after reviewing the literature related to watershed segmentation, we present a detailed end-to-end pipeline of algorithms to compute (hierarchical) watershed segmentations, starting from the computation of graph-based image representations, up to the computation of connected components of the final (hierarchical) segmentation. We consider the several variations of watersheds, including their supervised and unsupervised versions, and the various ways of computing seeds, to name a few. For the first time, we bring together all these watershed notions and algorithms in a compact and understandable way. We aim at providing a reference for those interested in employing and reimplementing the watershed segmentation framework for their task at hand.

0.36

ROCOCO: Robust Outline Completion of Occluded Curvilinear Objects

cs.CV cs.LG ·2026-10-21 ·Ken Zheng, Jaimyn Drake
similarity 0.48
Abstract

We propose a learning-based generative model for completing curvilinear features under occlusion by environmental obstacles. To this end, we adopt a flow matching-based approach that supports the inpainting of occluded regions with the appropriate curvilinear features. To eliminate the reliance on privileged information about the occlusion a priori, we also train a UNet-based mask prediction model, which can identify regions for inpainting given only the occluded observation. The components of our approach are validated via experiments using procedurally-generated test cases, and the complete pipeline is validated using large public datasets for curvilinear objects. Against off-the-shelf inpainting baselines, ROCOCO is the strongest method by a wide margin when no occlusion mask is given, and is competitive with mask-supervised inpainting when one is, achieving best on full-image error and second only to LaMa on the occluded region, while using a completer of $7.7$M parameters against LaMa's $51$M and Stable Diffusion's $860$M.

0.24

ContourVLA: A Closed-Loop Perception-Action Contour Policy for Generalized Referring Expression Segmentation

cs.CV ·2026-10-08 ·Ruicheng Zhang, Kaiwen Shen, Jiaqi Hou, Shuhan Yang, Junchao Huang +4 more
similarity 0.47
Abstract

Generalized referring expression segmentation (GRES) requires dynamically balancing high-level semantics for identifying a variable number of language-specified referents with fine-grained visual evidence for precise boundary delineation. This requirement challenges existing cascaded vision-language architectures, which typically rely on static feature interfaces and single-pass mask prediction, limiting adaptive perception and geometric correction. We introduce ContourVLA, a vision-language-action policy that recasts GRES as a closed-loop visuomotor process, in which editable contours serve as explicit policy states that condition multimodal perception and are updated by geometric action chunks. Evolution-Aware Semantic Scheduling (EASS) couples contour-guided bidirectional boundary sampling with state-conditioned routing of multilevel multimodal features, adapting perception to each contour state. Following supervised initialization, Dustbin-Augmented Entropic Credit Transport GRPO (DECT-GRPO) jointly optimizes discrete grounding and continuous contour actions with instance-level credits. Its rollout rewards and credits are derived from soft prediction-target correspondences that account for false positives and missed targets. ContourVLA improves gIoU over the strongest evaluated baselines by 8.7, 2.8, and 2.7 points on gRefCOCO val, testA, and testB, respectively, and achieves the highest mIoU across all eight RefCOCO, RefCOCO+, and RefCOCOg splits.

0.19

TMAL: Topology-preserving Multi-offset Affinity Learning for Curvilinear Structure Segmentation

cs.CV physics.med-ph ·2026-11-10 ·Suho Han, Soungsill Park, Kanghyun Ryu, Yoseob Han
code/datahot direction similarity 0.46
Abstract · 15 pages, 11 figures, submitted to WACV 2027

Curvilinear structures such as retinal vessels and surface cracks need both pixel-level accuracy and structural continuity. Pixel-wise supervision does not model the connections between pixels, and topology-based losses still produce ordinary masks. Connectivity-based methods predict these connections directly, but they use binary connectivity targets over a fixed local range. Such labels give the same value to thin segments and to thick regions, and they cannot describe connections at larger offsets. To address these limitations, we propose Topology-preserving Multi-offset Affinity Learning (TMAL). TMAL uses soft affinities that emphasize thin regions near the boundary, and it predicts directional affinities at several offsets to reach further. It then combines these affinities with weights that come from the decoder features, so local continuity and wider context are used together. An auxiliary segmentation branch adds region-level supervision and keeps the overlap accuracy high. On the retinal vessel dataset DRIVE and the crack inspection dataset DeepCrack, TMAL reaches the highest Dice, IoU, and clDice scores, and it greatly reduces the connected-component error $Δβ_0$. Code is available at https://github.com/suho-han/TMAL.

0.43

Inverse Rig Optimization from Line Drawings

cs.GR ·2026-09-01 ·Zihao Zhu, Yuki Koyama
similarity 0.46
Abstract · Pacific Graphics 2026

Stylized 3D character animation is largely hand-authored, with animators authoring rig parameters one keyframe at a time to find the best pose. Because stylized work reads chiefly through contour lines, drawing contours in the camera view is the most direct and precise way to express artistic intent. This mismatch between the rig controls and the artist's goal forces a laborious trial-and-error workflow, with animators repeatedly manipulating rig controls against the rendered view to match the desired contour. To address this, we propose a method that recovers rig parameters from screen-space contour strokes, enabling effective keyframing from sketches. Given strokes that redraw the current contour, our method optimizes the high-level rig parameters defined in the DCC tool. The key is to use a pre-trained MLP rig surrogate that provides a differentiable map from rig parameters to mesh vertices, replacing the original black-box rig within the optimization process. We match user-drawn lines to mesh contour lines and backpropagate the resulting screen-space error through the surrogate to update the rig parameters. Our results demonstrate that the method works for diverse characters and practical scenarios.

0.35

Depth-Dominant Skeleton Detection for Natural Scenes

cs.CV ·2026-08-17 ·Chengkun Rao, Yixuan Deng, Min Li, Yangjun Ou, Ye Li +5 more
similarity 0.46
Abstract · 11 pages, 3 figures, 4 tables

To date, all natural scene skeleton detection follows the paradigm of taking RGB images as the sole input; despite notable progress, methods under this paradigm suffer significant performance degradation on complex-content images. We observe that depth images are inherently insensitive to color and texture, and can provide clear regional contours and inter-region spatial relationships, which naturally alleviates the difficulty of skeleton detection in complex scenarios. Motivated by this observation, this paper proposes for the first time a novel skeleton detection paradigm where depth images serve as the dominant modality and RGB images act as the auxiliary, and accordingly presents a model DDSkel (short for Depth-Dominant Skeleton Detection) under this paradigm. DDSkel employs an asymmetric encoder design to fuse RGB information into depth features, with the RGB modality branch having only 12% the parameters of the depth modality branch. DDSkel has a simple structure without intricate designs. Nevertheless, with only 36% of the trainable parameters of the current best method, DDSkel outperforms all state-of-the-art approaches on SymPASCAL, the most challenging dataset with a large volume of complex images.

0.32