Skip to content

Repository files navigation

Virne Logo

A Comprehensive Simulator & Benchmark for NFV-RA

Ask DeepWiki

✨ Benchmark Paper   •   Documentation   •   Citations   •   SDN-NFV Papers


Virne is a simulator and benchmark for resource allocation (RA) in Network Functions Virtualisation (NFV), with unified support for traditional and reinforcement learning (RL)-based algorithms.

In the literature, RA in NFV is often termed Virtual Network Embedding (VNE), Virtual Network Function (VNF) placement, service function chain (SFC) deployment, or network slicing in 5G.

Virne offers a unified and comprehensive framework for NFV-RA, with the following key features:

  • 1️⃣ Highly Customizable Simulations: Simulates diverse network environments (e.g., cloud, edge, 5G), with user-defined topologies, resources, and service requirements.
  • 2️⃣ Extensive Algorithm Suite: Registers exact, heuristic, meta-heuristic, and learning-based solvers behind a common interface.
  • 3️⃣ Reinforcement Learning Support: Provides standardized RL pipelines and Gym-style environments for rapid development and benchmarking of RL-based solutions.
  • 4️⃣ In-depth Evaluation Aspects: Enables insightful analysis beyond effectiveness, covering multiple practicality perspectives (e.g., solvability, generalization, and scalability).

Important

🎉 The Virne benchmark paper has been accepted at ICLR 2026. Welcome to check it out!

✨ If you have any questions, please open a new issue or contact me via email (wtfly2018@gmail.com)

Citations

❤️ If you find Virne helpful to your research, please feel free to cite our related papers.

Benchmark Paper

[ICLR, 2026] Virne (paper)

@inproceedings{tfwang-2026-virne,
  title={Virne: A Comprehensive Benchmark for RL-based Network Resource Allocation in NFV},
  author={Wang, Tianfu and Deng, Liwei and Chen, Xi and Wang, Junyang and He, Huiguo and Hu, Zhengyu and Wu, Wei and Ding, Leilei and Fan, Qilin and Xiong, Hui},
  booktitle={The Fourteenth International Conference on Learning Representations},
  year={2026},
}

Algorithmic Papers

[IJCAI, 2024] FlagVNE (paper & code)

@INPROCEEDINGS{ijcai-2024-flagvne,
  title={FlagVNE: A Flexible and Generalizable Reinforcement Learning Framework for Network Resource Allocation},
  author={Wang, Tianfu and Fan, Qilin and Wang, Chao and Ding, Leilei and Yuan, Nicholas Jing and Xiong, Hui},
  booktitle={Proceedings of the 33rd International Joint Conference on Artificial Intelligence},
  year={2024},
}

[TSC, 2023] HRL-ACRA (paper & code)

@ARTICLE{tsc-2023-hrl-acra,
  author={Wang, Tianfu and Shen, Li and Fan, Qilin and Xu, Tong and Liu, Tongliang and Xiong, Hui},
  journal={IEEE Transactions on Services Computing},
  title={Joint Admission Control and Resource Allocation of Virtual Network Embedding Via Hierarchical Deep Reinforcement Learning},
  volume={17},
  number={03},
  pages={1001--1015},
  year={2024},
}

[ICC, 2021] DRL-SFCP (paper & code)

@INPROCEEDINGS{icc-2021-drl-sfcp,
  author={Wang, Tianfu and Fan, Qilin and Li, Xiuhua and Zhang, Xu and Xiong, Qingyu and Fu, Shu and Gao, Min},
  booktitle={ICC 2021 - IEEE International Conference on Communications}, 
  title={DRL-SFCP: Adaptive Service Function Chains Placement with Deep Reinforcement Learning}, 
  year={2021},
  pages={1-6},
}

Table of Contents

Quickstart

Installation

The installation script targets Linux and Python 3.10. Clone the repository, then create and activate a Conda environment:

git clone https://github.com/GeminiLight/virne.git
cd virne
conda create -n virne python=3.10
conda activate virne

Install either the CPU or CUDA 12.4 build:

# CPU-only PyTorch and PyG
bash install.sh -c cpu

# CUDA 12.4 with PyTorch 2.6.0
bash install.sh -c 12.4

Verify the installation from the repository root:

python -c "import virne; print(virne.__version__)"

Run a Small Experiment

Use a fast heuristic and ten VN requests for the first run. Calling python main.py without overrides starts the larger default RL experiment.

python main.py \
  solver.solver_name=nrm_rank \
  v_sim_setting.num_v_nets=10 \
  training.use_cuda=false \
  'logger.backends=[console]'

The run finishes with Complete and writes its resolved configuration, summary, and per-event records under:

results/virne/nrm_rank/<run-id>/

See the Quickstart for Hydra overrides and output details, and the solver registry for every valid solver command.

Implemented Algorithms

Virne has implemented a rich collection of exact, heuristic, meta-heuristic, and learning-based algorithms for NFV-RA. Some representative algorithms are listed below; see the generated solver registry for every command registered by the current code.

Learning-based Solvers

Name Command Type Mapping Title Publication Year Note
PG-CNN2 pg_cnn2 learning two-stage A Virtual Network EmbeddingAlgorithm Based On Double-LayerReinforcement Learning The Computer Journal 2022
GAE-Clustering gae_clustering learning bfs_trials Accelerating Virtual Network Embedding with Graph Neural Networks CNSM 2020 Clustering
PG-MLP pg_mlp learning joint_pr NFVdeep: adaptive online service function chain deployment with deep reinforcement learning. IWQOS 2019
Hopfield-Network hopfield_network learning two-stage NeuroViNE: A Neural Preprocessor for Your Virtual Network Embedding Algorithm INFOCOM 2018 Subgraph Extraction
PG-CNN pg_cnn learning two-stage A Novel Reinforcement Learning Algorithm for Virtual Network Embedding Neurocomputing 2018
MCTS mcts learning two-stage Virtual Network Embedding via Monte Carlo Tree Search TCYB 2018 MultiThreading Support

Meta-heuristics Solvers

Name Command Type Mapping Title Publication Year Note
Genetic-Algorithm ga_meta meta-heuristics two-stage Virtual network embedding based on modified genetic algorithm Peer-to-Peer Networking and Applications 2019 MultiThreading Support
Tabu-Search ts_meta meta-heuristics joint Virtual network forwarding graph embedding based on Tabu Search WCSP 2017 MultiThreading Support
ParticleSwarmOptimization pso_meta meta-heuristics two-stage Energy-Aware Virtual Network Embedding TON 2014 MultiThreading Support
Ant-Colony-Optimization aco_meta meta-heuristics joint Link mapping-oriented ant colony system for virtual network embedding CEC 2017 MultiThreading Support
Simulated-Annealing sa_meta meta-heuristics two-stage FELL: A Flexible Virtual Network Embedding Algorithm with Guaranteed Load Balancing ICC 2011 MultiThreading Support

Other Related Papers

  • Particle Swarm Optimization
    • Xiang Cheng et al. "Virtual network embedding through topology awareness and optimization". CN, 2012.
    • An Song et al. "A Constructive Particle Swarm Optimizer for Virtual Network Embedding". TNSE, 2020.
  • Genetic Algorithm
    • Liu Boyang et al. "Virtual Network Embedding Based on Hybrid Adaptive Genetic Algorithm" In ICCC, 2019.
    • Khoa T.D. Nguyen et al. "An Intelligent Parallel Algorithm for Online Virtual Network Embedding". In CITS, 2019.
    • Khoa Nguyen et al. "Efficient Virtual Network Embedding with Node Ranking and Intelligent Link Mapping". In CloudNet, 2020.
    • Khoa Nguyen et al. "Joint Node-Link Algorithm for Embedding Virtual Networks with Conciliation Strategy". In GLOBECOM, 2021.
  • Ant Colony Optimization
    • N/A

Heuristics-based Solvers

Name Command Type Mapping Title Publication Year Note
PL (Priority of Location) pl_rank heuristics two-stage Efficient Virtual Network Embedding of Cloud-Based Data Center Networks into Optical Networks TPDS 2021
NRM (Node Resource Management) nrm_rank heuristics two-stage Virtual Network Embedding Based on Computing, Network, and Storage Resource Constraints IoTJ 2018
GRC (Global resource capacity) grc_rank heuristics two-stage Toward Profit-Seeking Virtual Network Embedding Algorithm via Global Resource Capacity INFOCOM 2014
RW-MaxMatch (NodeRank) rw_rank heuristics two-stage Virtual Network Embedding Through Topology-Aware Node Ranking ACM SIGCOMM Computer Communication Review 2011
RW-BFS (NodeRank) rw_rank_bfs heuristics bfs_trials Virtual Network Embedding Through Topology-Aware Node Ranking ACM SIGCOMM Computer Communication Review 2011

Exact and Rounding Solvers

Name Command Type Mapping Title Publication Year Note
MIP (Mixed-Integer Programming) mip exact joint ViNEYard: Virtual Network Embedding Algorithms With Coordinated Node and Link Mapping TON 2012
D-Rounding (Deterministic Rounding) d_round rounding joint ViNEYard: Virtual Network Embedding Algorithms With Coordinated Node and Link Mapping TON 2012
R-Rounding (Random Rounding) r_round rounding joint ViNEYard: Virtual Network Embedding Algorithms With Coordinated Node and Link Mapping TON 2012

Simple Baseline Solvers

Name Command Mapping
Random Rank random_rank two-stage
Random Rank Breadth First Search random_rank_bfs bfs_trials
Order Rank order_rank two-stage
Order Rank Breadth First Search order_rank_bfs bfs_trials
First Fit Decreasing Rank ffd_rank two-stage

About

[ICLR '26 - Virne] A simulator & benchmark for resource allocation (RA) problems in network function virtualization (NFV), i.e., NFV-RA, including virtual network embedding, service function chain deployment, network slicing, etc.

Topics

Resources

Stars

158 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages