ictdesigntools.network.roadm¶
ROADM networks: nodes, the fibre links between them, and what a wavelength path through them sees: loss, filter narrowing, OSNR and latency.
A reconfigurable optical add/drop multiplexer (ROADM, ITU-T G.672) has one degree for each
fibre pair to a neighbouring node. A channel enters the network at one node's add port, is
expressed from degree to degree through each node it passes, and leaves at the far node's
drop port. Each of those is a chain of filter passes (optical.filters): in a
route-and-select node a wavelength selective switch (WSS) at the input degree and another at
the output, so an express path crosses two WSSs.
Network holds the nodes and links (to_graph() hands them to draw.graph).
route finds the shortest path by length, and path works out, along a route:
- the filter chain (add, then each express, then drop): its insertion loss and narrowed
passband, ready for
filters.check_passband; - the fibre loss of each link at the wavelength, from its fibre category (
optical.media); - the OSNR, when every node after the first has a pre-amplifier on its input degrees. A
node's booster, where it has one, makes up the loss of the add or express filters before
the link; each pre-amplifier makes up the link (and any filter loss no booster made up).
Every amplifier is one
osnr.Stage, so with boosters each link is launched at the power the channel had at the add port; - the channel's power after every filter, amplifier and link (
levels), whichpath_drawingdraws as a span diagram over a power-level chart; - the received power at the drop port, and the latency: the fibre's group delay at a group index of 1.4682 (typical of G.652 fibre at 1550 nm; Corning SMF-28 Ultra data sheet), about 4.9 µs/km, plus any delay a node adds.
>>> net = Network()
>>> for name in "ABCD":
... net.add(route_and_select(name, passband_ghz=75, preamp=Amplifier(5.5),
... booster=Amplifier(5.5)))
>>> net.link("A", "B", Link("G.652.D", 80))
>>> net.link("B", "C", Link("G.652.D", 70))
>>> net.link("C", "D", Link("G.652.D", 90))
>>> net.link("A", "D", Link("G.652.D", 300))
>>> net.route("A", "D")
('A', 'B', 'C', 'D')
>>> p = net.path("A", "D")
>>> p.length_km, round(p.latency_us), p.filter_loss_db, round(p.passband_ghz, 1)
(240.0, 1175, 44.0, 55.6)
>>> round(p.osnr.osnr_db, 1), p.received_dbm
(22.8, -10.0)
>>> net.degree("A")
2
>>> d = path_drawing(p) # the span diagram over the power-level chart
RoadmError ¶
Bases: ValueError
A node, link or path that cannot be worked out.
Roadm
dataclass
¶
Roadm(
name: str,
add: tuple[Filter, ...],
drop: tuple[Filter, ...],
express: tuple[Filter, ...],
preamp: Amplifier | None = None,
booster: Amplifier | None = None,
latency_us: float = 0.0,
)
A ROADM node: the filter passes a channel crosses when it is added, dropped, or
expressed from one degree to another; the pre-amplifier on each input degree and the
booster on each output degree (None when the node has none). latency_us is any delay
the node itself adds.
Link
dataclass
¶
A fibre pair between two nodes: length_km of one fibre category, plus
extra_loss_db for its connections, splices and ageing.
Level
dataclass
¶
The channel's power, per channel, just after an event at km along the path.
Network
dataclass
¶
ROADM nodes and the links between them (at most one link between two nodes).
degree ¶
route ¶
The shortest route from a to b by fibre length.
Source code in src/ictdesigntools/network/roadm.py
path ¶
path(
a: Hashable,
b: Hashable | None = None,
*,
route: Sequence[Hashable] | None = None,
wavelength_nm: float = 1550.0,
launch_dbm: float = 0.0,
) -> PathResult
A wavelength path added at a and dropped at b along the shortest route (or
along route, a list of nodes), with launch_dbm per channel at the add port.
Source code in src/ictdesigntools/network/roadm.py
to_graph ¶
to_graph() -> Graph
The network as a draw.graph.Graph for draw.graph.topology: nodes with
role="roadm" and their degree; edges with length_km and fiber.
Source code in src/ictdesigntools/network/roadm.py
route_and_select ¶
route_and_select(
name: str,
wss_loss_db: float = 6.0,
passband_ghz: float | None = None,
order: float = 3.0,
mux_loss_db: float = 4.0,
preamp: Amplifier | None = None,
booster: Amplifier | None = None,
) -> Roadm
A route-and-select node: a WSS on each input and output degree, and a mux/demux (or multicast switch) on the add/drop side. Expressing a channel crosses two WSSs; adding or dropping crosses one WSS and the mux or demux. Losses are typical planning values: replace them with the data sheet's.
Source code in src/ictdesigntools/network/roadm.py
path_drawing ¶
The path as a span diagram (nodes, links and amplifiers, spaced by distance) over a
chart of the channel's power along it, in mm. Each step of the chart is an event in
p.levels: a filter's loss, an amplifier's gain, or a link's loss along its length.
Source code in src/ictdesigntools/network/roadm.py
297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 | |