WorksComputer Science
From Partitioning to Provisioning: Co-Designing DNN Deployment and Infrastructure Capacity
Abstract
Deep neural network (DNN) partitioning enables distributed inference by dividing model computation across interconnected devices. Existing approaches have largely focused on optimizing DNN deployment over infrastructure with fixed computing and communication capacities. Yet when these resources cannot adequately support inference demands, optimizing deployment alone is insufficient: the supporting infrastructure must also be provisioned. Crucially, deployment and provisioning are inherently coupled. How a DNN is partitioned determines where capacity is needed, while capacity provisioning can fundamentally change the preferred deployment. Motivated by this interdependence, we investigate the co-design of DNN deployment and infrastructure capacity for pipelined inference. Despite the coupling between these decisions, we reveal an efficiently solvable structure: on acyclic networks, the problem admits an exact shortest-path reformulation, enabling globally optimal joint design in polynomial time. Numerical evaluations demonstrate the benefits of co-design over treating deployment and provisioning separately, highlighting the potential of inference-driven infrastructure planning.
Introduction
Distributed deep neural network (DNN) inference [1], [2] enables computationally demanding models to be executed across interconnected devices. A key enabling technique is DNN partitioning [3], [4], which distributes different portions of a model across devices. For streaming workloads, these portions can operate as a pipeline, allowing successive inputs to be processed concurrently [5], [6]. How to partition and deploy DNNs across computing networks has thus become a fundamental problem in distributed inference.
Existing research has largely approached this problem from a deployment perspective: given an infrastructure with fixed computing and communication capacities, how should a DNN be partitioned and deployed to achieve the best inference performance? Extensive efforts have been devoted to optimizing inference latency [3], [7], [8], throughput [2], [6], and other performance metrics [9], [10] under such resource constraints. While this perspective addresses how to make effective use of existing infrastructure, it leaves open a complementary question: how should the infrastructure itself be provisioned to support the inference workloads deployed on it?
The answer depends on the deployment itself. Partitioning determines where computation occurs and how much data traverses each link [3], [8], thereby shaping where additional capacity is needed. Yet capacity expansion can change which deployment is preferable: a deployment that maximizes throughput with existing resources may be far more expensive to upgrade than an alternative. Deployment and infrastructure capacity must therefore be designed jointly, rather than optimized in sequence.
In this paper, we develop such a co-design framework for pipelined DNN inference. Given a computing network with heterogeneous capacity costs, we jointly optimize the physical deployment path, the partitioning of DNN computational blocks, and the additional computing and communication capacities needed to sustain a target inference throughput. Although this problem couples discrete deployment choices with continuous provisioning decisions, we show that it possesses an exact and efficiently solvable structure on acyclic networks. The key insight is that the bottleneck-stage characterization of pipeline throughput allows the capacity requirements of individual stages to be determined locally. These requirements induce additive provisioning costs along a deployment path, enabling an exact reduction of the joint design problem to a shortest-path problem on a state graph.
The main contributions of this paper are summarized below:
We formulate an inference-infrastructure co-design problem that jointly determines DNN partitioning, deployment paths, and computing and communication capacity increments. Unlike fixed-capacity deployment optimization, our formulation treats infrastructure capacity as a design variable, allowing inference deployment and capacity provisioning to be optimized together.
We establish an exact equivalence between the co-design problem on acyclic networks and a shortest-path problem on an appropriately constructed state graph. Based on this structural result, we develop a dynamic programming algorithm that obtains a globally optimal solution in time and space.
We evaluate the proposed approach on 400 instances with VGG-16 and ResNet-50 workloads. Compared with two heuristic provisioning strategies that do not jointly optimize deployment and capacity expansion, our approach achieves substantial cost reductions, with median cost ratios reaching 25 and worst-case ratios exceeding 100. These results highlight the importance of co-designing DNN deployment and its supporting infrastructure capacity.
Problem Formulation
We first describe how DNN deployment and network capacities determine pipelined inference throughput, and then formulate the minimum-cost co-design problem under a target throughput requirement.
DNN Deployment Model
The distributed computing network is modeled as a directed graph , where and denote the sets of physical nodes and directed links, respectively. The network contains a source node and a destination node , with , and at least one path from to is assumed to exist. Each node has existing computing capacity , measured in floating-point operations per second. Each link has existing communication capacity , measured in bits per second. We collect the existing capacities into the vectors and .
The DNN is represented by an ordered sequence of heterogeneous blocks, each of which may be a single layer or a module such as a residual or inception module. To characterize the computation and data transfer requirements, let denote the number of floating-point operations required by block , for ; and let denote the activation size in bits after the first blocks, for . Thus, is the raw input size and is the final output size. To express the computing workload of consecutive blocks assigned to a node, we define the prefix workload and
A node executing blocks then requires floating-point operations.
A DNN deployment specifies both the physical route through the network and how consecutive DNN blocks are assigned to nodes on that route. We represent it by a path and a vector of partition points . The path is defined as
where is the number of nodes on , and denotes its -th node. Let be the set of all such paths. For each , the vector of partition points is
Let be the set of all such vectors, where denotes the non-negative integers. For , denotes the number of DNN blocks completed along up to and including node . Accordingly, node executes blocks . If , the node performs no computation and only forwards the activation. After a node completes its assigned blocks, it sends the activation of size over the link .
Pipelined Throughput
In pipelined execution, the inference consists of computation stages and communication stages. We consider steady-state pipelined inference with sufficient buffering and no resource contention, where computation and communication stages can overlap across successive inputs. The slowest stage determines the output interval, whose reciprocal gives the inference throughput [8]. For a deployment , the computation time at each node equals its assigned workload divided by its computing capacity. Hence, the maximum computation-stage delay is
For , let be the -th link on . The corresponding communication time depends on the activation size and link capacity, giving the maximum communication-stage delay
The output interval is therefore
The minimum achievable output interval over all feasible deployments is
and the maximum achievable inference throughput under these capacities is .
The Minimum-Cost Co-Design Problem
Suppose the inference service requires a throughput of at least , where , or equivalently, an output interval no greater than . The goal is to meet this requirement at minimum provisioning cost by jointly determining the DNN deployment and capacity increments.
For every node , let be the increment added to , and for every link , let be the increment added to . We collect these increments into the vectors and . Since the cost of adding capacity can vary across the network, let and be the unit prices of computing capacity and communication capacity, respectively, and collect them into the vectors and . We consider linear provisioning costs for simplicity. The proposed method also applies to costs that are separable across nodes and links, non-decreasing in each capacity increment, and zero at zero increment.
After provisioning, the required throughput is achievable if . We therefore formulate the minimum-cost co-design problem as
If the existing network already meets the throughput requirement, the optimal provisioning cost is zero. Otherwise, although (4) explicitly optimizes only and , the physical path and partition points are implicitly optimized through in (3). Since the preferred deployment can change with variable capacities, deployment and provisioning decisions are coupled. In the next section, we exploit the acyclic network structure to obtain an exact solution to this co-design problem.
Exact Co-Design on Acyclic Networks
Cost-Weighted State Representation
We represent the deployment decisions in (4) using an auxiliary state graph , where is the set of states and is the set of state transitions, both defined later in this section. Two edge weight functions are defined in Sections III-A1 and III-A2, respectively.
Introduce a virtual terminal node . For each node, let denote its feasible block indices, with , for every , and . The set of states (vertices of ) is therefore . A state means that the activation after block has arrived at , before processes any further blocks. In particular, means that the raw input has arrived at and no DNN blocks have yet been executed; means that all blocks have been processed and the final output is available at .
Introduce a virtual link with and , so that the weight formulas below apply to . The set of state transitions (edges of ) is
For , define , , , .
We call a simple path from to in a state path, and let be the set of all state paths. For each , let be the set of transitions between states of $r. Figure 1 illustrates for a simple network. We next define the delay and provisioning cost associated with each state transition.

Figure 1. The state graph for a small example with one intermediate node and links , . Each transition carries the cost weight needed to meet the throughput constraint. The highlighted state path selects the physical path and the partition points. The vertical dots represent omitted states with indices and their incident transitions.
Delay of Transitions
1) Delay of Transitions: For a transition , the computation at and communication over form two pipeline stages. Under capacity increments and , its delay is represented as the larger of their delays:
The following lemma shows that state paths preserve both the deployment choices and their output intervals.
Lemma 1: If is acyclic, the mapping defines a bijection between and . Moreover, if is the state path corresponding to , then
Proof: Forward map. Given , let and define for . By (1) and (2), each consecutive pair belongs to . The resulting sequence starts at and ends at , and thus defines a state path .
Inverse map. Let be represented by the sequence , where , , , and . By (5), for all . Since is acyclic, are pairwise distinct, and hence . Moreover, since for all , . Thus, the forward and inverse constructions are mutually inverse, proving the bijection.
Interval equality. Each transition represents the computation at node followed by transmission over its outgoing link. Let . Since , the final transition has zero communication delay. Therefore,
By (3) and Lemma 1, the minimum output interval can be expressed entirely over state paths:
Cost of Transitions
2) Cost of Transitions: By (6), a state path meets the throughput target if every transition on it has a delay no greater than . For each , is equivalent to
Together with the non-negativity constraints, these inequalities give the minimum computing and communication capacity increments required by :
where . Using the unit capacity prices, we define the provisioning cost of transition as
An Exact Shortest-Path Solution
Lemma [1] establishes a correspondence between DNN deployments and state paths, while gives the minimum
Algorithm 1 Provisioning on a State Graph (PSG)
Input: $G = (\mathcal{V}, \mathcal{E})$, $C$, $B$, $Q_1,\ldots,Q_N$, $D_0,\ldots,D_N$, $\beta$, $\boldsymbol{\pi}^{\mathrm{comp}}$, $\boldsymbol{\pi}^{\mathrm{comm}}$
Output: optimal physical path $p^*$, partition points $b_{p^*}$, and capacity increments $\mathbf{x}^*,\mathbf{y}^*$
1: compute $S_0,\ldots,S_N$ and a topological order $v_1,\ldots,v_{|\mathcal{V}|}$ of $\mathcal{V}$; set $v_{|\mathcal{V}|+1}\leftarrow\tau$
2: $\operatorname{dist}(s,0)\leftarrow 0$, $\operatorname{dist}(v,i)\leftarrow+\infty$ for all other states, and clear $\operatorname{pred}$
3: for $d=1,\ldots,|\mathcal{V}|+1$ do
4: for all $i\in I_{v_d}$ with $\operatorname{dist}(v_d,i)<+\infty$ do
5: for all $(v_d,z)\in\mathcal{E}\cup\{e_\tau\}$ do
6: for all $j\in I_z$ with $j\ge i$ do
7: $\xi\leftarrow((v_d,i),(z,j))$
8: compute $w(\xi)$
9: if $\operatorname{dist}(v_d,i)+w(\xi)<\operatorname{dist}(z,j)$ then
10: $\operatorname{dist}(z,j)\leftarrow\operatorname{dist}(v_d,i)+w(\xi)$
11: $\operatorname{pred}(z,j)\leftarrow(v_d,i)$
12: end if
13: end for
14: end for
15: end for
16: end for
17: backtrack $\operatorname{pred}$ from $(\tau,N)$ to $(s,0)$ into a state path $r^*$
18: return $(p^*,b_{p^*},\mathbf{x}^*,\mathbf{y}^*)$ from $r^*$ as in the proofs of {xref}`Lemma 1` and {xref}`Theorem 1`, of cost $\operatorname{dist}(\tau,N)$
provisioning cost for each transition. If the physical network is acyclic, no physical node or link is used more than once along a state path. These costs can therefore be added along the path, leading to the following exact equivalence.
Theorem 1. If is acyclic, the optimal value of problem (4) equals the shortest path distance from to in with as the edge weight function, i.e., . Moreover, if a shortest state path is found, an optimal solution of (4) can be derived accordingly.
Proof. For any transition , the delay requirement and non-negative capacity increments give
Let . For any feasible , (6) guarantees a state path satisfying for every . Since is acyclic, no physical node or link appears more than once on . Thus, by (7) and the non-negative capacity prices,
Conversely, let be a shortest state path, and set and for all of , with all other increments set to zero. By (7), this allocation is feasible. Since no physical resource is repeated along ,
The corresponding deployment follows from Lemma 1. ▪
By Theorem 1, the co-design problem reduces to a shortest-path problem on when is acyclic. Since every state transition follows a physical link or , a topological order of , with placed last, also gives a topological order of the state graph. We can therefore solve the problem by dynamic programming without explicitly constructing . Maintain a label , set to at and elsewhere. Each transition is relaxed according to
Processing states in topological order yields the optimal cost . The predecessor pointers recover the corresponding deployment and capacity increments, as detailed in Algorithm 1.
Proposition 1. Algorithm 1 returns an optimal solution of (4) in time and space.
Proof. Optimality follows from Theorem 1, since the relaxations in (8) are performed in topological order. The state graph has states and transitions. Each transition is processed once, and its weight is computed in time. Since transitions are generated on demand from , the state graph need not be explicitly stored. Thus, only distance labels and predecessor pointers are required. ▪
The same algorithm applies to the separable, non-decreasing provisioning costs described in Section II-C. It suffices to redefine , where and are non-decreasing on and zero at zero.
Numerical Results
We evaluate the benefit of minimum-cost co-design by comparing PSG (Algorithm 1) with two provisioning heuristics that use throughput-optimal deployments to guide capacity upgrades. The experiments consider randomly generated tiered networks with VGG-16 and ResNet-50 workloads.
Both heuristics use throughput-optimal deployments to guide provisioning, without accounting for capacity prices. PFP (Provisioning under Frozen-Partitioning) fixes an initial throughput-optimal deployment and purchases the minimum capacity increments needed to meet . PWF (Provisioning with Water-Filling) reduces the bottleneck stage delays of the current deployment to the next lower delay level or , and recomputes a throughput-optimal deployment after each upgrade. When (3) admits multiple throughput-optimal deployments, PWF selects one of them (the first found by the solver) rather than enumerating all optima. For any ,
| Entity | Distribution | Unit |
| , source & access tier | GFLOP/s | |
| , middle tier | GFLOP/s | |
| , remote tier & | GFLOP/s | |
| , links to access tier | Mbps | |
| , links to middle tier | Mbps | |
| , links to remote tier & | Mbps | |
| , nodes | per GFLOP/s | |
| , links | per Mbps |
Table 1. Capacities and unit prices (: uniform; LU: log-uniform).
let and denote and in Section III-A2 with replaced by . Algorithm 2 summarizes PWF, which terminated on all tested instances.
The DNN workloads are analytic block profiles of VGG-16 () and ResNet-50 () with inputs. Block workloads and activation sizes are derived from layer shapes, assuming FP32 activations and two floating-point operations per multiply-accumulate, with max-pooling folded into the preceding VGG-16 block and global average pooling folded into the last ResNet-50 block.
We generate 50 tiered DAGs, each consisting of a source , three intermediate tiers (access, middle, and remote) with 2–3 nodes each, and a destination . Each node has 1–3 randomly selected links to the next tier, except remote-tier nodes, which each connect to . The resulting networks contain 8–11 nodes and at least one path from to . Existing capacities and unit prices follow the distributions in Table I.
For each topology and DNN, we set , where . Since , all instances require additional capacity. Using the same 50 topologies for both DNNs yields instances. We measure the ratio of each heuristic’s provisioning cost to the optimal cost obtained by PSG.
Figure 2 compares the provisioning-cost ratios over all 400 instances. PFP incurs median ratios of 5.1–8.6 for VGG-16 and 6.5–25.3 for ResNet-50, with worst cases of 144 and 639, respectively. PWF matches the optimum in 80% of ResNet-50 instances at , but its median ratios remain 4.1–9.4 for VGG-16 and reach 5.6 for ResNet-50, with a worst case of 44. For VGG-16, the median ratios of both heuristics increase as decreases, reaching 8.6 (PFP) and 9.4 (PWF) at .

Figure 2. The cost ratio of PWF and PFP to PSG versus the relative target on all 400 instances: VGG-16 (top) and ResNet-50 (bottom). Boxes span interquartile ranges, whiskers extend to the interquartile range, diamonds mark means, dots mark individual instances, and the dashed line marks the exact optimum; the vertical axis is logarithmic.
The cost gap reflects a key difference: the heuristics choose capacity upgrades without considering prices, whereas PSG minimizes price-weighted costs across feasible deployments. These results show that joint optimization can lead to much lower provisioning costs, even when deployment is updated during provisioning. In our Python implementation on an AMD Ryzen 7 8845H CPU, the median runtimes are 0.25, 0.28, and 1.8 ms for PSG, PFP, and PWF, respectively, showing that PSG remains computationally efficient on the tested instances.
Conclusion
This paper established an exact approach to co-designing DNN deployment and infrastructure capacity over acyclic
networks. Beyond the algorithmic result, the broader insight is that the value of computing and communication capacity depends on how it serves the inference workload as a whole, rather than on individual resources in isolation. This points toward a fundamental shift in AI infrastructure planning: from expanding available resources to strategically provisioning capacity where it delivers the greatest end-to-end benefit.
References
References
- [1]S. Teerapittayanon, B. McDanel, and H.-T. Kung, “Distributed deep neural networks over the cloud, the edge and end devices,” in IEEE Int. Conf. Dist. Comp. Syst. (ICDCS), 2017, pp. 328–339.arxiv.org/abs/1709.01921
- [2]Z. Zhao, K. Mirzazad Barijough, and A. Gerstlauer, “DeepThings: Distributed adaptive deep learning inference on resource-constrained IoT edge clusters,” IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, vol. 37, no. 11, pp. 2348–2359, 2018.DOI
- [3]Y. Kang, J. Hauswald, G. A. Rovinski, T. Mudge, J. Mars, and L. Tang, “Neuroseason: Collaborative intelligence between the cloud and mobile edge,” in ACM ASPLOS, 2017, pp. 615–629.
- [4]A. E. Eshratifar, M. S. Abrishami, and M. Pedram, “JointDNN: An efficient training and inference engine for intelligent mobile cloud computing services,” IEEE Transactions on Mobile Computing, vol. 20, no. 2, pp. 565–576, 2021.
- [5]N. R. Hadidi, J. Cao, M. S. Ryoo, and H. Kim, “Toward collaborative inferencing of deep neural networks on internet-of-things devices,” IEEE Internet of Things Journal, vol. 7, no. 6, pp. 4950–4960, 2020.DOI
- [6]Y. Hu, C. Imes, X. Zhao, S. Kundu, P. A. Beerél, S. P. Crago, and J. P. Walters, “PipeEdge: Pipeline parallelism for large-scale model inference on heterogeneous edge devices,” in IEEE DSD, 2022, pp. 298–307.DOI
- [7]E. Li, L. Zeng, Z. Zhou, and X. Chen, “Edge AI: On-demand accelerating deep neural network inference via edge computing,” IEEE Trans. Wireless Commun., vol. 19, no. 1, pp. 447–457, 2020.arxiv.org/abs/1910.05316
- [8]C. Hu, W. Bao, D. Wang, and F. Liu, “Dynamic adaptive DNN surgery for inference acceleration on the edge,” in IEEE INFOCOM, 2019.
- [9]L. Zeng, X. Chen, Z. Zhou, L. Yang, and J. Zhang, “CoEdge: Cooperative DNN inference with adaptive workload partitioning over heterogeneous edge devices,” IEEE/ACM Transactions on Networking, vol. 29, no. 2, pp. 595–608, 2021.arxiv.org/abs/2012.03257
- [10]S. Laskaris, S. I. Venieris, M. Almeida, I. Leontiadis, and N. D. Lane, “SPINN: Synergistic progressive inference of neural networks over device and cloud,” in ACM MobiCom, 2020.