arXiv:2609.00400cs.DCAug 2026

Manuscript Offprint

arXiv:2609.00400

Client-side transparent caching for remote ROOT data analysis

Dmytro Kovalskyi, Jan Eysermans, Mariarosaria D'Alfonso, Christoph Paus

Abstract

High-energy physics analyses often process the same data as physicists refine algorithms and test new ideas. With data increasingly read from remote storage, each iteration is subject to network latency and depends on network bandwidth and shared-storage throughput, which can vary substantially under load. We present uCache (xrd-ucache), a transparent client-side cache implemented as an XRootD client plugin that requires neither server-side deployment nor changes to analysis code. It uses local storage on the analysis machine as a cache layer between the network and memory. The cache stores only the data actually read by an analysis. It can also rebuild cached data into a branch-aligned, recompressed form, eliminating most of the input/output and decompression costs of subsequent passes. We benchmark the cache using the Analysis Grand Challenge top quark pair analysis on public CMS Open Data compressed with zlib and LZMA. Filling the cache adds essentially no overhead compared with a direct read. Subsequent passes are 1.6–8.8 times faster from the byte cache and 2.1–15.7 times faster from the recompressed cache. For a typical analysis, a 1 TB cache suffices for datasets of 10–20 TB. The largest improvements occur when the remote data source is heavily loaded or geographically distant.

1 Introduction

High-energy physics analysis is an iterative process. A result is rarely produced by writing the final analysis once and running it over the data. Instead, physicists develop an idea, implement it in code, process the data, inspect the output and use what they learn to decide what to try next. Each cycle may involve changing an event selection, testing a different observable, comparing alternative background models, checking a possible bias or investigating an unexpected feature in the data.

The speed of this cycle directly affects how thoroughly an analysis can be explored. When each iteration takes a long time, the number of ideas that can be tested is limited; when feedback is fast, physicists can explore more alternatives, investigate unexpected observations, and identify weak approaches or possible biases earlier. Faster feedback allows physicists to test more alternatives and make better-informed choices in the final analysis.

Physicists working on experiments at the CERN LHC analyze many billions of events. Even in a compact format such as CMS NanoAOD [1], the data used by a single analysis can total tens of terabytes, reaching the 100 TB scale. Processing such large volumes typically relies on local computing clusters or distributed computing resources, and producing complete results can take considerable time. Additional delays can arise from transient failures or periods of high demand for computing resources.

Resource contention is particularly important because shared computing systems are expensive. Such systems are generally optimized for scheduled, large-scale processing rather than on-demand tasks that require rapid turnaround. Even a relatively small or urgent request may have to wait until sufficient resources become available. Interactive data analysis is therefore often performed

*Corresponding author: kdv@mit.edu on personal laptops or dedicated workstations, where users have direct control over the available resources and can prioritize workloads according to their immediate needs.

To achieve acceptable turnaround, physicists use several methods to reduce the amount of data to process. The two most important methods are event skimming and slimming. Event skimming selects a small subset of relevant events by applying preselection requirements, while slimming reduces the size of each event by removing information that is not needed for the analysis.

Both approaches can be highly effective. However, reducing a dataset to a size that can be processed on an individual computer often requires a reduction of 3 to 4 orders of magnitude. Such a large reduction can restrict experimentation because less information remains available for testing alternative analysis strategies. It also commonly requires an additional, time-consuming processing step to produce so-called final flat ntuples, which are then used for statistical inference and other final analysis tasks.

To mitigate these issues, column-based ntuples are widely used. These ntuples store data by branch, allowing rapid access to only the required information. Although columnar ntuples such as NanoAOD can be read very efficiently [2, 3], they require a significant amount of storage to retain all information that may be useful. For a collaboration-wide data format such as NanoAOD, this often means that only a small fraction of the stored data are needed for a particular analysis, despite the large amount of disk space required for the complete dataset.

These datasets can be read directly from remote storage using the XRootD protocol [4], which avoids the need to keep a full local copy. However, each pass over the data then depends on the network and the remote storage system: file opens alone can add tens of seconds per pass over a wide-area link (Section 4.2), the throughput of a shared origin can change by a factor of a few within an hour (Section 4.5), and a temporary server error can interrupt an entire job. A local cache reduces these problems by retrying failed reads and serving repeatedly accessed data locally, without contacting the remote server again.

The case for placing that cache on the analysis machine itself is structural. A modern NVMe device delivers several gigabytes per second at tens of microseconds: more than a 10 GbE network path carries, and far more than a fair per-client share of any shared network layer in a balanced deployment (Section 4.7 measures the network case directly). Local storage is therefore the fastest layer an physicist can place between the machine's memory and the remote infrastructure. Today that layer usually serves as scratch space; uCache turns it into a durable cache.

Analysts can use uCache to turn local SSD or NVMe storage into a fast cache on a laptop or workstation. It is implemented as an XRootD client plugin that end users can install without administrator support, server-side modifications or changes to the analysis code. Rather than storing complete files, it caches only the parts of each file that the analysis reads. For repeated passes, it can reorganize the cached data into a compact local copy, called the "replica tier," reorganized by branch, matching the order in which an analysis reads, and recompressed for faster access. This organization reduces the number of storage operations and the amount of decompression required in later passes.

On suitable cache storage, the first pass, which fills the cache, adds almost no overhead compared with reading the data directly from remote storage. If the cache encounters an internal error, uCache automatically falls back to forwarding requests to the remote server, allowing the analysis to continue without depending on the cache. By storing only the data that the analysis actually reads, rather than complete files, a 1 TB local cache can support a typical analysis over datasets totaling 10–20 TB or more.

Throughout this paper, measured quantities refer to one reference setup: the Analysis Grand Challenge (AGC) ttˉt\bar{t} analysis reading two public CMS Open Data NanoAOD datasets, one zlib-compressed (1.8 TB) and one LZMA-compressed (2.4 TB), with roughly 6% of the bytes fetched per pass, on machines ranging from a 6-core desktop on a residential fiber connection to a 192-core analysis-facility node. Section 3 defines the datasets, the machines and the measurement protocol.

The remainder of this paper is organized as follows. Section 2 describes the design of uCache. Section 3 introduces the benchmark analysis, the data samples, the test machines and the measurement protocol. Section 4 presents the results, beginning with end-to-end runtimes and then examining the mechanisms behind them. It also compares uCache with XCache, the established site-level caching solution, evaluates uCache with ROOT's RNTuple format, the successor to TTree, and measures how sensitive the results are to the ROOT version (Sections 4.7, 4.8, and 4.9). Section 5 discusses the limits of the approach, Section 6 reviews related work, and Section 7 states the conclusions. Software and data availability, including the complete list of datasets used, is described in Section 8 and the appendices.