- add the per degree info using the EXACT next node uid as identifier
of the degree
- add the degree identifier on the propagate and call functions
Signed-off-by: EstherLerouzic <esther.lerouzic@orange.com>
This might have nothing to do with the ITU frequency grid (it's really
just about a uniform distribution), so let's give it a more readable
name and more readable parameters.
Both of these places referred to "eq. 123 from arXiv:1209.0394", the
only difference (apart from the source of the input parameters, beta2
and asymptotic_length) was calling the two branches "SCI" and "XCI" vs.
"SPM" and "XPM".
In this commit I've only moved the code to a single implementation. The
input data are still being read from the same parameters, of course.
For some reason, the code allowed using "convenience names" for
accessing properties since commit 58ac717f. To me, this looks like an
obvious anti-pattern because accessing a single property via three
different names only makes the code less readable. Let's kill this
"feature".
In case of the `Power` class, the code used "ase" and "nli" on the
majority of places, so let's use these abbreviations instead of their
spelt-out variants.
SpectralInformation was "clean" already, but there were calls to the
`update()` wrapper around the `namedtuple._replace`. Given that there
were no property aliases, it's safe to just call `_replace()` directly.
In case of the `Pref` class, once again always use `p_span0`, `p_spani`
instead of `p0` and `pi` -- it's a trivial change.
Rather than do the None-dance and document the default value within a
docstring, let's use the default value directly. This is safe because
numbers are immutable.
Because default arguments are evaluated *once*, not every time they are
called, a mutable default value is not "reset", and this happens:
>>> from gnpy.core.node import Node
>>> x=Node('123')
>>> y=Node('456')
>>> print(x.metadata)
{'location': Location(latitude=0, longitude=0, city=None, region=None)}
>>> print(y.metadata)
{'location': Location(latitude=0, longitude=0, city=None, region=None)}
>>> y.metadata['foo']=123
>>> print(x.metadata)
{'location': Location(latitude=0, longitude=0, city=None, region=None), 'foo': 123}
This is easily fixable by using an immutable value as a placeholder
here.
This feature is intended to support designs such as OpenROADM where the
line degree integrates a specific preamp/booster pair. In that case, it
does not make sense for our autodesign to "pick an amplifier". The
restrictions can be activated by:
- Listing them in `eqpt_config.json`, so that they are effective for all
ROADM instances.
- On a per-ROADM basis within the Excel sheet or the JSON definitions.
Restrictions apply to an entire ROADM as a whole, not to the individual
degrees.
If a per-degree exception is needed, the amplifier of this degree can be
defined in the equipment sheet or in the network definition.
If no booster amplifier should be placed on a degree, use the `Fused`
node in place of an amplifier.
Signed-off-by: Esther Le Rouzic <esther.lerouzic@orange.com>
Co-authored-by: Jan Kundrát <jan.kundrat@telecominfraproject.com>
While the `itufl()` function uses THz by default, its values depend on
the frequency range that is passed via arguments. In this context, the
f_min and f_max come from the default SpectralInformation which is in
Hz.
Thanks to @ojnas for reporting this.
fixes#243
exception KeyError type in service sheet not correctly catched
print Request.mode instead of Requestmode (not defined at this point)
selection of modes did not respect min spacing criterium:
constraint added
transmission_main did not give SNR in 0.1 nm: added in std out
Signed-off-by: EstherLerouzic <esther.lerouzic@orange.com>
-add f_min & f_max frequency definition in amplifier json
-improve interpolation algorithm to support length differences between the spectrum information and the amplifier ripple and dgt frequency definition
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
set individual channel powers wrto the target reference power
tilt and ripple is eliminated after the Roadm
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
power mode no longer reads operational_gain:
now reads operational.dp_db
or calculate optimum dp_db from next span loss
gain_mode:
reads operational.gain_target
or use gain_from_dp
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
squash to dp
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
support min gain for raman auto-design:
raman amplification is only considered for a span if its gain > specified
min gain of the raman hybrid in eqpt_config
auto-design was checked succesfully when enabling a mix of 6 possible different
amplifiers: low gain, medium gain, hybrid ramans, high power and high
gain amplifiers. They were picked as expected.
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
quick & dirty 1st implementation:
-fixed raman nf and gain,
-no tilt, no ripple,
-no nonlinear contribution,
-no pump power reduction from egress con loss
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
add Tx_osnr or add_drop_osnr on raw snr values to avoid cumulated adding
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
bug fix: forgot to add add_drop_osnr with tx_osnr
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>
save and be able to retrieve the carrier information processed by Edfa
and Fiber elements:
@ input & output of the element
- channel power: ase, nli, signal and total
Signed-off-by: Jean-Luc Auge <jeanluc.auge@orange.com>