We present a one-shot method for compressing large labeled graphs called Random Edge Coding. When paired with a parameter-free model based on P\'olya's Urn, the worst-case computational and memory complexities scale quasi-linearly and linearly with the number of observed edges, making it efficient on sparse graphs, and requires only integer arithmetic. Key to our method is bits-back coding, which is used to sample edges and vertices without replacement from the edge-list in a way that preserves the structure of the graph. Optimality is proven under a class of random graph models that are invariant to permutations of the edges and of vertices within an edge. Experiments indicate Random Edge Coding can achieve competitive compression performance on real-world network datasets and scales to graphs with millions of nodes and edges.
翻译:我们提出了一种名为随机边编码的一次性方法,用于压缩大型标记图。当与基于波利亚罐模型的无参数模型配合使用时,最坏情况下的计算复杂度和内存复杂度分别随观测边数呈准线性和线性增长,使其在稀疏图上高效运行,且仅需整数运算。该方法的关键在于比特回传编码,它用于从边列表中无放回地采样边和顶点,同时保持图的结构。在边置换和边内部顶点置换不变的一类随机图模型下,该方法的最优性得以证明。实验表明,随机边编码可在真实网络数据集上实现有竞争力的压缩性能,并能扩展至包含数百万节点和边的图。