![]() |
LINE Solver (C++)
Templated C++ port of the LINE queueing solver
|
Variational inference for Markovian queueing networks. More...
#include <algorithm>#include <array>#include <cmath>#include <cstddef>#include <limits>#include <numeric>#include <vector>#include "line/num/number.h"#include "line/util/error.h"#include "line/util/matrix.h"Go to the source code of this file.
Classes | |
| struct | line::infer::VariationalSpec< T > |
| Inference problem handed to infer_variational. More... | |
| struct | line::infer::VariationalOptions< T > |
| Options of infer_variational; a negative box means "derive a default". More... | |
| struct | line::infer::VariationalResult< T > |
| Outcome of infer_variational. More... | |
Namespaces | |
| namespace | line |
| namespace | line::infer |
Enumerations | |
| enum class | line::infer::VariationalSched { line::infer::INF = 0 , line::infer::SHARED = 1 , line::infer::EXTERNAL = 2 } |
| Service discipline of a station, as seen by the load factor Upsilon. More... | |
Functions | |
| template<class T> | |
| VariationalResult< T > | line::infer::infer_variational (VariationalSpec< T > spec, VariationalOptions< T > opt=VariationalOptions< T >()) |
| Run the variational inference procedure. | |
Variational inference for Markovian queueing networks.
Port of matlab/src/api/infer/infer_variational.m and of the JAR twin jline.inference.api.Infer_variational, following I. Perez, G. Casale, "Variational Inference for Markovian Queueing Networks", Advances in Applied Probability 53(3), 2021.
The network trajectory is reparameterised by the transition counts Y^eta, eta = (i,j,c), so that the station marginals decouple:
x_{i,c}(t) = x_{i,c}(0) + sum_{eta in In(i,c)} Y^eta(t)
The variational family is a product of inhomogeneous pure-birth processes, one per transition, with rate nu^eta(t,y), times a product of Gamma densities over the unknown service rates. The state space is expanded by adding DELTA to every feasible rate, so that queue lengths may go negative and the approximating measure stays mutually absolutely continuous with the target; the original model is recovered as DELTA -> 0.
Each iteration performs, per transition, a backward pass for the Lagrange multipliers r^eta with multiplicative jumps at the observation epochs, the rate update nu^eta(t,y) = exp(E log Xi^eta(t,y)) r^eta(t,y+1)/r^eta(t,y), and a forward pass of the master equation for the marginal. The conjugate Gamma posteriors are then refreshed from the expected number of firings and the expected exposure time of each station-class pair.
ARITHMETIC: the backward and forward passes are uniformizations, i.e. convex combinations of sub-stochastic matrix actions, so they stay positive and bounded whatever the rate scale. The transcendental content is exp, log and the digamma of the Gamma posteriors; there is no random-number stream, since the expectations over the other transitions are taken on a Halton lattice mapped through the inverse marginal c.d.f. The estimator therefore reproduces the MATLAB, Java and Python implementations digit for digit.
Definition in file infer_variational.h.