
CyNetDiff: A Python Library for Accelerated Implementation of Network Diffusion Models
Jan 12, 2026 • Software
CyNetDiff is a Python package for accelerating network diffusion simulations, recently accepted into the pyOpenSci ecosystem.
Network diffusion models study how information and epidemics spread over social networks, and have garnered increasing interest in recent years. Two of the most widely used models are the independent cascade (IC) and linear threshold (LT) models. These models simulate spread through a network by starting with a set of seed nodes that are designated as “active”, and all other nodes are “inactive”. Then, in each iteration, some inactive nodes become active, and the iterations continue until no other nodes can be activated.
Many tasks related to these models, particularly influence maximization, require running simulations on large graphs many times, which can be computationally expensive. There has been significant prior work on reducing the number of simulations needed for these tasks, demonstrating the importance of an efficient implementation.
While researchers often prefer high-level languages like Python for their flexibility and quick development, these computationally intensive tasks are better suited for low-level, compiled languages. To bridge this gap, we’ve developed CyNetDiff, a Python library that uses components written in Cython to provide the performance of a compiled language with the flexibility of a high-level language.
Keep reading
Maintain Python code quality in Quarto Markdown files using lintquarto
lintquarto is a package for running linters, formatters, static type checkers and code analysis tools on Python code in Quarto markdown (.qmd) files.
Read moreNavigating LLMs in Open Source: pyOpenSci's New Peer Review Policy
Generative AI products are reducing the effort and skill necessary to generate large amounts of code. In some cases, this strains volunteer peer review programs like ours. Learn about pyOpenSci’s …
Read moreQuadratiK: Collection of Methods Constructed using Kernel-Based Quadratic Distances
QuadratiK provides a set of goodness-of-fit tests, a clustering technique using kernel-based quadratic distances, and algorithms for generating random samples from Poisson kernel-based distributions …
Read more