Manuscript Offprint

arXiv:2610.11115

Dynamics as Code: On Model Compression via Dynamic System

Fan Gao, Wei Su, Juntong Fan, Renfeng Peng, Hongyu Liu, Jinqiao Duan, Feng-Lei Fan

Fan Gao, Wei Su*, Juntong Fan*, Renfeng Peng, Hongyu Liu, Jinqiao Duan, Feng-Lei Fan

Abstract—The escalating size of pretrained neural networks has rendered model compression a prerequisite for deployment under stringent memory and compute constraints. With the irrational winding as an example, earlier work introduced a dynamic system (DS) paradigm that reconceptualizes compression as compact weight representation: high-dimensional parameters are encoded by the index of a trajectory produced by a dynamic system, from which the vector is recovered during decompression. This mechanism is fundamentally distinct from pruning, quantization, knowledge distillation, and low-rank decomposition. Along this direction, we prove that under a Diophantine condition, a finite trajectory of M=O(ϵ−(d+ν))M = O(\epsilon^{-(d+\nu)}) states in the irrational winding constitutes an ϵ\epsilon-net over the d-dimensional weight space, thereby linking state resolution, decompression error, and compression ratio in a predictable manner. Furthermore, we propose a generalized DS-based model compression framework by unifying four DS families—space-filling curves (Hilbert, Peano, Morton/Z-order, Snake), chaotic systems (Lorenz), congruential and pseudo-random generators (LCG, PCG), and low-discrepancy sequences (Halton). Also, we introduce the KD-tree and coordinate-template acceleration to scale to large models as well as outlier identification to control the error. Experiments on ResNet-18 and Qwen2.5-1.5B/Qwen1.5-7B validate that DS-based compression achieves competitive compression ratios without post-hoc retraining, with controllable decompression error and flexible state-space design, establishing it as a principled and practical compression approach.

Index Terms—Model compression, dynamic systems, neural networks, parameter representation.

I. INTRODUCTION

In the past decade, the emergence of large-scale pretrained models creates substantial deployment challenges, particularly in resource-constrained settings such as workstations, smartphones, and wearables [1]. Loading LLaMA-2 70B weights in FP16 precision requires approximately 140 GB, nearly six times the memory capacity of an NVIDIA GeForce RTX 4090 [2]. The development of multimodal world models [3], [4] is likely to further worsen this issue due to the introduction of vision and speech encoders alongside extended context lengths. Consequently, model compression has emerged as a critical strategy for serving large models, aiming to minimize storage requirements without compromising task performance [5]. This is quite different from the pre-large-model era, where model sizes remained modest, and the incentives for compression were comparatively weak.

Classical model compression methods fall into four primary categories: pruning, quantization, knowledge distillation, and low-rank decomposition [6]: i) Pruning removes unimportant parameters or structural components [7], which pursues the parameter sparsity within a model; ii) Quantization reduces the numerical precision of weights and activations (e.g., FP32 → INT8/INT4) to decrease storage and bandwidth requirements [8]; iii) Knowledge distillation transfers knowledge from a large teacher model to a compact student model [9], [10], which typically requires additional training, task data, and careful teacher-student design; iv) Low-rank factorization approximates weight matrices or tensors using the low-rank decomposition [11]. The achievable compression depends on the intrinsic rank of weights, and can vary substantially across layers, architectures, and tasks. In essence, classical methods exploit different forms of redundancy in the original parameter space such as sparsity, reduced numerical precision, or low-rank structure.

Recently, inspired by the biological genomic bottleneck [12], a novel basic mechanism for model compression was discovered and engineered in [13], which uses the ergodicity principle that a low-dimensional dynamic system can fill the high-dimensional space. Mathematically, given target weights w=[w1,…,wN]⊤\mathbf{w} = [w_1, \ldots, w_N]^\top, [13] employs irrational winding to construct a function h(θ;n)h(\theta; n) to approximate each weight such that wn≈h(θ;n)w_n \approx h(\theta; n), where the number of trajectory parameters θ\theta is significantly smaller than the total number of weights ( dim⁡(θ)≪N\dim(\theta) \ll N). This turns model compression into a problem of parsimonious parameter representation. Model compression via dynamic systems is not merely incremental. Instead, it shifts away from decades-old techniques by opening new research directions at the intersection of dynamic systems and efficient deep learning, while also being practically viable for billion-parameter models in resource-constrained settings. Introducing dynamic systems carves out a new research direction in model compression. Nevertheless, several critical theoretical and methodological challenges must be addressed to fully realize the potential of this approach:

Theoretically, the relationship between the compression ratio and the error remains unexplored. Due to the non-locality of the irrational winding, to achieve the same level of error, how large θ\theta needs to be at least is intractable. Accordingly, the compression ratio is unpredictable. This is a fundamental question in this domain, and solving it will transform the dynamic system from a heuristic into a principled, predictable tool. For example, one can predict to

Fan Gao and Wei Su are with the School of Information Science and Engineering, Lanzhou University, Lanzhou, Gansu Province, China; Feng-Lei Fan, Renfeng Peng, and Juntong Fan are with the Department of Data Science, City University of Hong Kong, Hong Kong, China SAR; Hongyu Liu is with the Department of Mathematics, City University of Hong Kong, Hong Kong, China SAR; Jinqiao Duan is with the School of Science, Great Bay University, Dongguan, China; Wei Su (suwei@lzu.edu.cn) and JunTong Fan are co-corresponding authors.

what extent increasing θ\theta will surely reduce the approximation error, thereby providing the lower bound for the compression ratio and facilitating allocating bits across layers fairly. Methodologically, since model compression via dynamic systems is general, can we enrich the armory of this kind by effectively engineering other dynamic systems? The dynamic system (DS) theory provides a broader design space beyond the irrational winding. Instead of treating irrational winding as the default choice, a broader design space of transformation-induced compression mappings characterized by different coverage, locality, and indexability properties should be examined.

In this manuscript, we theoretically establish both the asymptotic feasibility and the practical optimizability of DS-based compression. First, the covering guarantee (Theorem 1) establishes that, under Diophantine conditions, M=O(ϵ−(d+ν))M = O(\epsilon^{-(d+\nu)}) trajectory states form an ϵ\epsilon-net over the weight space, directly linking the compression ratio to the reconstruction error through the covering radius. This justifies why a low-dimensional scalar can approximate high-dimensional weights with bounded distortion. Second, the optimization procedure addresses the discontinuity of the irrational winding by partitioning the domain at all breakpoints; within each continuous segment, the loss reduces to a convex quadratic with a closed-form minimizer, enabling exact global minimization. Together, these results transform the theoretical density guarantee into a practical, deterministic algorithm with a predictable error profile, ensuring that the mechanism is not merely an existence statement. Methodologically, we expand this novel framework from a single ergodic construction to a broader toolbox, i.e., space-filling curves, chaotic dynamics, pseudo-random sequences, and low-discrepancy sequences, which cover representative DS families:

• Space-filling and grid traversal mappings (Hilbert [14], Peano [15], Morton/Z-order [16], and Snake traversal): deterministic mappings from compact indices to high-dimensional grid points, offering different locality-preserving structures for grouped weight representation.

• Chaotic-system-based mappings (Lorenz system [17]): nonlinear trajectory-based mappings that provide aperiodic coverage of the weight representation space beyond regular grid traversal.

• Congruential and pseudo-random generator mappings (Linear Congruential Generator (LCG) [18] and Permuted Congruential Generator (PCG)): efficient deterministic point generators that produce reproducible pseudo-random sequences with simple indexable structures for scalable compression.

• Quasi-Monte Carlo sequences (Halton [19]): deterministic low-discrepancy sequences that provide uniform coverage for compact weight representation.

These families differ in coverage guarantees, computational cost, and approximation accuracy, thereby leading to different compression ratios, speed, and decompression fidelity. The central problem in developing DS-based compression is how to enable fast, accurate, and scalable compression. We introduce effective engineering techniques such as KD-tree to speed up the compression speed and outlier identification to control the error. Particularly, for the space-filling curves, we design the coordinate template method to further accelerate the compression relative to the KD-tree search.

In brief, our contributions are threefold:

• We lay a solid theoretical foundation for model compression based on dynamic systems by illustrating the asymptotic feasibility. To the best of our knowledge, it is the first theoretical result in the direction of DS-based model compression.

• We build a general framework for model compression via dynamic systems, engage mainstream dynamic systems as the components, and design engineering techniques to make this framework scalable to large models.

• Systematic and comprehensive experiments confirm that DS-based model compression can deliver competitive performance on ResNet and large models such as Qwen2.5-1.5B and Qwen1.5-7B.

References (65)