Skip to content

feat(rank): add TOPSIS-based node ranking for VNE - #44

Open
stark256-spec wants to merge 1 commit into
GeminiLight:mainfrom
stark256-spec:feat/topsis-node-rank
Open

feat(rank): add TOPSIS-based node ranking for VNE#44
stark256-spec wants to merge 1 commit into
GeminiLight:mainfrom
stark256-spec:feat/topsis-node-rank

Conversation

@stark256-spec

Copy link
Copy Markdown

Summary

Adds a TOPSIS (Technique for Order of Preference by Similarity to Ideal Solution) node ranking algorithm and its corresponding two-stage solver to Virne.

What changes

virne/solver/rank/node_rank.py — new TOPSISNodeRank class registered as 'topsis':

  • Builds a decision matrix whose rows are substrate nodes and whose columns are their available resource attributes (CPU, memory, …) concatenated with the aggregate available bandwidth of each node's incident links.
  • Euclidean-normalises each column, applies equal weights (all criteria are benefit-type), then computes TOPSIS positive and negative ideal solutions.
  • Scores each node by its closeness coefficient dist_neg / (dist_pos + dist_neg). Nodes closest to the ideal resource profile receive the highest score and are placed first during VNE.

virne/solver/heuristic/node_rank.py — new TOPSISRankSolver registered as 'topsis_rank':

  • Wraps TOPSISNodeRank inside the existing BaseNodeRankSolver two-stage pipeline.
  • Invoked with python main.py solver.solver_name=topsis_rank.

docs/source/solver/overview.md — adds topsis_rank row to the heuristics solver table.

Motivation

TOPSIS is a well-established MCDM method for multi-criteria node selection that provides a principled distance-to-ideal scoring without requiring iterative convergence (unlike GRC or RW). It naturally handles heterogeneous resource dimensions and produces scores in [0, 1] that are directly interpretable as embedding priority.

Adds TOPSISNodeRank to virne/solver/rank/node_rank.py and the
corresponding TOPSISRankSolver to virne/solver/heuristic/node_rank.py.

The ranker treats each substrate node as a TOPSIS alternative whose
criteria are its available resource attributes (CPU, memory, etc.)
concatenated with the aggregate available bandwidth of its incident
links. The TOPSIS closeness coefficient — proximity to the ideal
resource profile — becomes the node ranking score used by the two-stage
mapping pipeline.

Algorithm:
  1. Build decision matrix: node resources || aggregate link resources
  2. Euclidean-normalise each criterion column
  3. Apply equal weights across all criteria (all benefit-type)
  4. Compute positive and negative ideal solutions
  5. Score each node by dist_neg / (dist_pos + dist_neg)

Usage:
  python main.py solver.solver_name=topsis_rank

Docs: adds topsis_rank row to docs/source/solver/overview.md.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant