Repository navigation
This release introduces several breaking changes, new fiber-modeling capabilities,
accuracy improvements, and more consistent YANG-compatible output formats.
It also improves transceiver feasibility evaluation by adding receiver
power constraints, detailed receiver modeling, and Q-margin calculation.
Breaking changes
Python and dependency requirements
Support for Python versions older than 3.11 has been dropped.
GNPy has been updated to use more recent versions of its main dependencies.
In particular, execution of the scripts now requires NumPy 2.x.
The main dependency updates are:
| package | from | to |
| -------------------- | ------ | ------ |
| alabaster | 0.7.21 | 1.0.0 |
| docutils | 0.17.1 | 0.22.4 |
| matplotlib | 3.7.3 | 3.10.8 |
| networkx | 3.1 | 3.6.1 |
| numpy | 1.24.4 | 2.4.0 |
| pandas | 2.1 | 2.3.3 |
| pbr | 6.0.0 | 7.0.3 |
| psutil | 7.0.0 | 7.2.1 |
| pygments | 2.11.2 | 2.19.2 |
| pytest | 7.4.3 | > 8 |
| scipy | 1.10.1 | 1.16.3 |
| sphinx | 8.1.3 | 9.1.0 |
| sphinxcontrib-bibtex | 2.6.4 | 2.6.5 |
| sphinx_rtd_theme | 3.0.2 | 3.10.8 |
| xlrd | 2.0.1 | 2.0.2 |
The following deprecated NumPy APIs have also been replaced:
numpy.trapzhas been replaced withnumpy.trapezoid.- The deprecated
newshapeargument ofnumpy.reshapehas been replaced
with theshapeargument.
Channel numbering and spectrum propagation
Channel numbering now starts at channel 0.
Previously, the number of channels used during design was computed as:
(f_max - f_min) / spacing
whereas propagation used one fewer channel and started at
f_min + spacing. This behavior has been aligned.
For a given Spectrum Information (SI):
- the number of channels is now identical during design and propagation;
- the first channel is located at
f_min; - the last channel is located at
f_max; - both boundary frequencies are included.
This is a breaking change and may modify channel assignments, propagation
results, and spectrum-related outputs.
Spectrum assignment boundaries
Spectrum bitmap boundaries are now handled consistently with the configured
frequency range.
The upper bitmap bound includes the slot corresponding to f_max. Allocations
starting exactly at n_min are also accepted; only allocations starting below
n_min are rejected.
This change ensures that the first and last available frequency slots are
included in the spectrum bitmap and prevents valid allocations at the lower
boundary from being rejected.
Fiber modeling
A frequency-dependent fiber loss model can now be declared as a list in the
equipment file and referenced from the topology file through type_variety.
This avoids duplicating the complete model definition for every fiber instance
in the topology file.
Once a model has been instantiated in the topology, its loss can be customized
using the legacy loss_coef scalar. The model is scaled so that, at
ref_frequency, its value matches the specified loss_coef.
This preserves the legacy topology-level configuration while allowing reusable
frequency-dependent loss models to be defined in the equipment library and
selected through type_variety.
When both a legacy dictionary-based model and a list-based model are provided,
the legacy dictionary-based model takes precedence.
Accuracy improvements
Cumulative chromatic dispersion
Cumulative chromatic dispersion is now computed directly from the fiber
dispersion parameter.
Previously, chromatic dispersion was evaluated from the beta2 and beta3
parameters used internally by the simulation. This could lead to incorrect
results when a dispersion slope was provided.
The new behavior ensures that cumulative chromatic dispersion follows the
dispersion model defined in the fiber parameters.
The existing behavior of using a constant beta2 when no dispersion slope is
specified is preserved for nonlinear interference evaluation. As beta2 and
chromatic dispersion cannot both remain constant over frequency, their values
may differ when a constant beta2 is used.
Spectrum slot width
The slot width is now taken directly from the spectral_info data instead of
being recomputed.
This avoids inconsistencies between the configured Spectrum Information and the
slot width used internally by the simulation.
YANG-compatible output
JSON exports have been updated to conform to the YANG model.
The corresponding corrections also apply to CSV exports and command-line output.
In particular:
- YANG validation is now enforced for all JSON exports;
- per-label averages with a value of
Noneare no longer exported; - cumulative results are exported per label;
- transmission results containing mixed rates are averaged per label instead of
being averaged over the entire spectrum; - per-label results are now displayed consistently in command-line output.
These changes may modify the structure or content of generated JSON and CSV
results, as well as command-line output.
Receiver-aware feasibility evaluation
Transceiver modes can now define minimum and maximum received channel-power
limits. A mode is considered infeasible when the received power falls outside
these limits.
The following parameters are supported:
rx-channel-power-min-dbm;rx-channel-power-max-dbm.
These constraints are evaluated per carrier, allowing different requirements
for channels using different transceiver modes.
Q-margin calculation
Detailed receiver parameters can now be provided for a transceiver mode through
the detailed_rx configuration.
When detailed receiver parameters are available, GNPy calculates the receiver
BER and derives a Q-margin from the configured BER threshold. The Q-margin is
then used for path feasibility evaluation and automatic mode selection.
When no detailed receiver information is provided, GNPy continues to use the
standard OSNR-based feasibility calculation.
Per-carrier transceiver parameters
Transceiver mode information is now propagated through the spectral information
on a per-carrier basis.
The following parameters can therefore be associated with individual carriers:
- required OSNR;
- impairment penalties;
- minimum and maximum received channel power;
- detailed receiver parameters.
This enables mixed-rate and mixed-mode spectra to be evaluated using
carrier-specific performance requirements.
Transceiver roles
Transceivers are now explicitly identified as emitters or receivers during
propagation.
Receiver-specific calculations, including received power, receiver penalties,
receiver noise contribution, and feasibility evaluation, are performed only
by the receiving transceiver.
YANG model updates
The YANG models have been updated to support detailed receiver parameters and
the corrected transmitted and received power-range field names.
The updated YANG model revision is 2026-05-28. The following fields are
now used:
tx-channel-power-min-dbm;tx-channel-power-max-dbm;rx-channel-power-min-dbm;rx-channel-power-max-dbm.
Users relying on previous YANG revisions or previous power-range field names
should update their equipment and service configurations.
Transceiver output power
When tx_power is not explicitly provided in a service request, GNPy now
uses the tx-channel-power-max-dbm value defined by the selected
transceiver mode, when available. This value takes precedence over the default
SI tx_power_dbm setting and is used for mode feasibility evaluation and
subsequent propagation.
Bug fixes
- Fixed the computation of cumulative chromatic dispersion when a dispersion
slope is defined. - Fixed channel propagation so that it starts with channel 0.
- Fixed spectrum bitmap boundary handling.
- Fixed the inclusion of the maximum frequency slot in the OMS spectrum bitmap.
- Fixed the acceptance of allocations starting at the minimum spectrum index.
- Fixed the conversion of
nmaxvalues used for spectrum assignment. - Fixed the display of per-label results.
- Fixed JSON export validation and YANG conformance issues.
- Replaced a non-ASCII arrow character with
->to improve compatibility with
macOS environments.
Documentation and maintenance
- Updated the linter configuration.
- Updated imports used by the documentation generation process to avoid
conflicts between thejson_ioandelementsmodules in Sphinx autodoc. - Prepared the project for the next release of
oopt-gnpy-libyangby limiting
the release number until cross-platform compatibility is confirmed.