Giter Site home page Giter Site logo

telecominfraproject / oopt-gnpy Goto Github PK

View Code? Open in Web Editor NEW
201.0 201.0 87.0 12.53 MB

Optical Route Planning Library, Based on a Gaussian Noise Model

Home Page: http://telecominfraproject.com

License: BSD 3-Clause "New" or "Revised" License

Python 99.95% Shell 0.01% Dockerfile 0.03%
mesh-networks optical-network python route-optimization route-planning telecominfraproject

oopt-gnpy's People

Contributors

aleferrari avatar andreadamico avatar berahtlv avatar briantaylor89 avatar davidboertjes avatar diegolaunch avatar dutc avatar estherlerouzic avatar florian1frank avatar gborrach avatar ggrammel avatar giladg-fb avatar jeanluc-auge avatar jktjkt avatar mcantono avatar miquelga avatar mnaser avatar ojnas avatar samialavi avatar szhu3210 avatar xufengliu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

oopt-gnpy's Issues

testing gnpy with coronet example

2018-04-16 successfully installing GNPY followingthe readme
Trying using GNPY with the Coronet example as described in our Readme:

execution was from the GNPY directory:


> ggrammel-mbp:gnpy

ls
README.rst		examples		setup.py
contributors.md		gnpy
docs			requirements.txt

ggrammel-mbp:gnpy ggrammel$ python examples/transmission_main_example.py examples/coronet_conus_example.json
Traceback (most recent call last):
  File "examples/transmission_main_example.py", line 106, in <module>
    exit(main(args))
  File "examples/transmission_main_example.py", line 38, in main
    with open(args.filename) as f:
FileNotFoundError: [Errno 2] No such file or directory: 'examples/coronet_conus_example.json'

I then checked for the presence of this file and realized the name probably changed to
examples/coronet.conus.json

now trying with

ggrammel-mbp:gnpy ggrammel$ python examples/transmission_main_example.py examples/coronet.conus.json
Traceback (most recent call last):
  File "examples/transmission_main_example.py", line 106, in <module>
    exit(main(args))
  File "examples/transmission_main_example.py", line 41, in main
    network = network_from_json(json_data)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 29, in network_from_json
    g.add_node(getattr(elements, el_config['type'])(el_config))
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/elements.py", line 107, in __init__
    self.length = self.params.length * \
AttributeError: 'Fiber' object has no attribute 'params'

is the Readme to be updated or is our main branch broken?

Newcomer feedback from lattelecom

In TIP Workplace managed to find Polito model presentation and as I understood actual code is using these principles. This kind of info, at least for me, is helpful to understand the model.

As not professional coder and with no experience with open-source projects I don’t understand the principles how new functions are added (organizational task) – someone adds something and then hopes for pull approvement or there are some guidelines what functions project is missing at the moment and these are pursued with high priority (something besides Raman model).

On fresh Ubuntu 18.04 installation, as i remember, besides requirements.txt python3.6-tk installation was needed.
Readme doesn’t mention that this library is using python 3.6, only the onboarding guide. In Ubuntu 16.04 with default python 3.5 additional repository is needed for ‘apt install python3.6’ to work.

Results output in console are understandable, as was mentioned in the call JSON result output would be good idea - simplify gnpy integration somewhere.

Already opened a few issues:
· ROADM loss
o After looking in Polito model presentation it is much clearer how ROADM model can look in the future
o If for some purposes channel drop power calculation would be needed, then losses should be divided in three parts – add_loss, drop_loss, express_loss. Calculation of these for network.json can be made by front end
o For low loss spans only preamplifier can be needed (no booster). At the moment all hops are automatically calculated with Preamp and Booster

· EDFA parameters and booster-less type
o Introduction of Booster-less amplifiers
o Mentioned Gain calculation from ‘Power/channel@output – Power/channel@input’ is just like our vendor equipment is configured and can be recalculated for Gain parameter by front end

In general, two modes of operation would be needed:
· Automatic – auto calculation of better Amp and so on
· Manual/Manual-Auto – calculation with manually entered parameters (Amp, fiber, span padding, …), that is helpful if performance calculation is made including already commisioned network equipment (old network + new network or ROADM direction), sometimes only particular card types are better choice (spare parts, end of sale)

testing gnpy after fresh install: error running examples

2018-04-16: after testing the installation using pip install I realized that timestamps in the local folder gnpy were older than the master (see separate issues)

  1. Then I deleted an older gnpy folder and started afresh, cloning from master.
  2. the timestamps of files were actual (as expected)
  3. running the first example from Readme --> no success
  4. running second example from Readme --> no success

IOW I wasn't able to run the examples from Readme

ggrammel-mbp:github ggrammel$ git clone https://github.com/Telecominfraproject/gnpy**
Cloning into 'gnpy'...
remote: Counting objects: 694, done.
remote: Compressing objects: 100% (8/8), done.
remote: Total 694 (delta 1), reused 3 (delta 0), pack-reused 685
Receiving objects: 100% (694/694), 349.50 KiB | 501.00 KiB/s, done.
Resolving deltas: 100% (365/365), done.
ggrammel-mbp:github ggrammel$ cd gnpy
ggrammel-mbp:gnpy ggrammel$ python setup.py install
/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
  warnings.warn(msg)
running install
running bdist_egg
running egg_info
creating gnpy.egg-info
writing gnpy.egg-info/PKG-INFO
writing dependency_links to gnpy.egg-info/dependency_links.txt
writing requirements to gnpy.egg-info/requires.txt
writing top-level names to gnpy.egg-info/top_level.txt
writing manifest file 'gnpy.egg-info/SOURCES.txt'
reading manifest file 'gnpy.egg-info/SOURCES.txt'
writing manifest file 'gnpy.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-10.6-intel/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/gnpy
copying gnpy/__init__.py -> build/lib/gnpy
creating build/lib/gnpy/core
copying gnpy/core/__init__.py -> build/lib/gnpy/core
copying gnpy/core/elements.py -> build/lib/gnpy/core
copying gnpy/core/execute.py -> build/lib/gnpy/core
copying gnpy/core/info.py -> build/lib/gnpy/core
copying gnpy/core/network.py -> build/lib/gnpy/core
copying gnpy/core/node.py -> build/lib/gnpy/core
copying gnpy/core/units.py -> build/lib/gnpy/core
copying gnpy/core/utils.py -> build/lib/gnpy/core
creating build/bdist.macosx-10.6-intel
creating build/bdist.macosx-10.6-intel/egg
creating build/bdist.macosx-10.6-intel/egg/gnpy
copying build/lib/gnpy/__init__.py -> build/bdist.macosx-10.6-intel/egg/gnpy
creating build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/__init__.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/elements.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/execute.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/info.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/network.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/node.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/units.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
copying build/lib/gnpy/core/utils.py -> build/bdist.macosx-10.6-intel/egg/gnpy/core
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/__init__.py to __init__.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/__init__.py to __init__.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/elements.py to elements.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/execute.py to execute.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/info.py to info.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/network.py to network.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/node.py to node.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/units.py to units.cpython-36.pyc
byte-compiling build/bdist.macosx-10.6-intel/egg/gnpy/core/utils.py to utils.cpython-36.pyc
creating build/bdist.macosx-10.6-intel/egg/EGG-INFO
copying gnpy.egg-info/PKG-INFO -> build/bdist.macosx-10.6-intel/egg/EGG-INFO
copying gnpy.egg-info/SOURCES.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO
copying gnpy.egg-info/dependency_links.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO
copying gnpy.egg-info/requires.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO
copying gnpy.egg-info/top_level.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating dist
creating 'dist/gnpy-0.1.3-py3.6.egg' and adding 'build/bdist.macosx-10.6-intel/egg' to it
removing 'build/bdist.macosx-10.6-intel/egg' (and everything under it)
Processing gnpy-0.1.3-py3.6.egg
Copying gnpy-0.1.3-py3.6.egg to /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Adding gnpy 0.1.3 to easy-install.pth file

Installed /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy-0.1.3-py3.6.egg
Processing dependencies for gnpy==0.1.3
Searching for xlrd==1.1.0
Best match: xlrd 1.1.0
Adding xlrd 1.1.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for urllib3==1.22
Best match: urllib3 1.22
Adding urllib3 1.22 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for sphinxcontrib-websupport==1.0.1
Best match: sphinxcontrib-websupport 1.0.1
Adding sphinxcontrib-websupport 1.0.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for sphinxcontrib-bibtex==0.3.6
Best match: sphinxcontrib-bibtex 0.3.6
Adding sphinxcontrib-bibtex 0.3.6 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for Sphinx==1.6.6
Best match: Sphinx 1.6.6
Adding Sphinx 1.6.6 to easy-install.pth file
Installing sphinx-apidoc script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing sphinx-autogen script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing sphinx-build script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing sphinx-quickstart script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for snowballstemmer==1.2.1
Best match: snowballstemmer 1.2.1
Adding snowballstemmer 1.2.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for six==1.11.0
Best match: six 1.11.0
Adding six 1.11.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for scipy==1.0.0
Best match: scipy 1.0.0
Adding scipy 1.0.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for requests==2.18.4
Best match: requests 2.18.4
Adding requests 2.18.4 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for PyYAML==3.12
Best match: PyYAML 3.12
Adding PyYAML 3.12 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pytz==2017.3
Best match: pytz 2017.3
Adding pytz 2017.3 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for python-dateutil==2.6.1
Best match: python-dateutil 2.6.1
Adding python-dateutil 2.6.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pytest==3.3.2
Best match: pytest 3.3.2
Adding pytest 3.3.2 to easy-install.pth file
Installing py.test script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing pytest script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pyparsing==2.2.0
Best match: pyparsing 2.2.0
Adding pyparsing 2.2.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for Pygments==2.2.0
Best match: Pygments 2.2.0
Adding Pygments 2.2.0 to easy-install.pth file
Installing pygmentize script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pybtex-docutils==0.2.1
Best match: pybtex-docutils 0.2.1
Adding pybtex-docutils 0.2.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pybtex==0.21
Best match: pybtex 0.21
Adding pybtex 0.21 to easy-install.pth file
Installing pybtex script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing pybtex-convert script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing pybtex-format script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for py==1.5.2
Best match: py 1.5.2
Adding py 1.5.2 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for pluggy==0.6.0
Best match: pluggy 0.6.0
Adding pluggy 0.6.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for oset==0.1.3
Best match: oset 0.1.3
Adding oset 0.1.3 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for numpy==1.13.3
Best match: numpy 1.13.3
Adding numpy 1.13.3 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for networkx==2.0
Best match: networkx 2.0
Adding networkx 2.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for matplotlib==2.1.0
Best match: matplotlib 2.1.0
Adding matplotlib 2.1.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for MarkupSafe==1.0
Best match: MarkupSafe 1.0
Adding MarkupSafe 1.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for latexcodec==1.0.5
Best match: latexcodec 1.0.5
Adding latexcodec 1.0.5 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for Jinja2==2.10
Best match: Jinja2 2.10
Adding Jinja2 2.10 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for imagesize==0.7.1
Best match: imagesize 0.7.1
Adding imagesize 0.7.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for idna==2.6
Best match: idna 2.6
Adding idna 2.6 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for docutils==0.14
Best match: docutils 0.14
Adding docutils 0.14 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for decorator==4.1.2
Best match: decorator 4.1.2
Adding decorator 4.1.2 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for cycler==0.10.0
Best match: cycler 0.10.0
Adding cycler 0.10.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for chardet==3.0.4
Best match: chardet 3.0.4
Adding chardet 3.0.4 to easy-install.pth file
Installing chardetect script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for certifi==2017.11.5
Best match: certifi 2017.11.5
Adding certifi 2017.11.5 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for Babel==2.5.3
Best match: Babel 2.5.3
Adding Babel 2.5.3 to easy-install.pth file
Installing pybabel script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for attrs==17.4.0
Best match: attrs 17.4.0
Adding attrs 17.4.0 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for alabaster==0.7.10
Best match: alabaster 0.7.10
Adding alabaster 0.7.10 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Searching for setuptools==38.5.1
Best match: setuptools 38.5.1
Adding setuptools 38.5.1 to easy-install.pth file
Installing easy_install script to /Library/Frameworks/Python.framework/Versions/3.6/bin
Installing easy_install-3.6 script to /Library/Frameworks/Python.framework/Versions/3.6/bin

Using /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages
Finished processing dependencies for gnpy==0.1.3
ggrammel-mbp:gnpy ggrammel$ python examples/transmission_main_example.py
Traceback (most recent call last):
  File "examples/transmission_main_example.py", line 90, in <module>
    exit(main(args))
  File "examples/transmission_main_example.py", line 41, in main
    network = network_from_json(json_data)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 29, in network_from_json
    g.add_node(getattr(elements, el_config['type'])(el_config))
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/elements.py", line 222, in __init__
    super().__init__(config)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/node.py", line 48, in __init__
    self.config = ConfigStruct(**config)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/node.py", line 31, in __init__
    json_config = load_json(config['config_from_json'])
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/utils.py", line 20, in load_json
    with open(filename, 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: 'edfa_config.json'
ggrammel-mbp:gnpy ggrammel$ python examples/transmission_main_example.py examples/coronet_conus_example.json
Traceback (most recent call last):
  File "examples/transmission_main_example.py", line 90, in <module>
    exit(main(args))
  File "examples/transmission_main_example.py", line 42, in main
    build_network(network)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 119, in build_network
    network = split_fiber(network, fiber)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 86, in split_fiber
    network = add_egress_amplifier(network, prev_node)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 108, in add_egress_amplifier
    new_edfa = Edfa(config)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/elements.py", line 222, in __init__
    super().__init__(config)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/node.py", line 48, in __init__
    self.config = ConfigStruct(**config)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/node.py", line 31, in __init__
    json_config = load_json(config['config_from_json'])
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/utils.py", line 20, in load_json
    with open(filename, 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: 'edfa_config.json'
ggrammel-mbp:gnpy ggrammel$ 
ggrammel-mbp:gnpy ggrammel$ ls -l examples/
total 296
-rw-r--r--   1 ggrammel  wheel  132604 Apr 16 19:19 coronet_conus_example.json
drwxr-xr-x   7 ggrammel  wheel     238 Apr 16 19:19 edfa
-rw-r--r--   1 ggrammel  wheel    9973 Apr 16 19:19 edfa_config.json
drwxr-xr-x  12 ggrammel  wheel     408 Apr 16 19:19 edfa_model
-rw-r--r--   1 ggrammel  wheel    3241 Apr 16 19:19 transmission_main_example.py
ggrammel-mbp:gnpy ggrammel$ 

transmission_main_example.py does not seem to work anymore with CORONET_Global_Topology.xls file

  • some input nodes are no more accepted
    python3 examples/transmission_main_example.py examples/CORONET_Global_Topology.xls Abilene Dallas is raising an stopIteration error although it is defined as a link: probably because all no nodes type are given and 2 degree nodes are set as ILA by default
    -> Question: should we keep this example working ? or can we change it and add required type info on Nodes sheet ?

  • amplifiers are not correctly inserted at the end of spans during build_network
    I could not find why...

here is an example:
python3 examples/transmission_main_example.py examples/CORONET_Global_Topology.xls dallas houston

invalid node type (ILA) specified in Dallas, replaced by ROADM
invalid node type (ILA) specified in El_Paso, replaced by ROADM
invalid node type (ILA) specified in Syracuse, replaced by ROADM
invalid node type (ILA) specified in Albuquerque, replaced by ROADM
invalid node type (ILA) specified in Denver, replaced by ROADM
invalid node type (ILA) specified in Las_Vegas, replaced by ROADM
invalid node type (ILA) specified in Amsterdam, replaced by ROADM
invalid node type (ILA) specified in New_York, replaced by ROADM
invalid node type (ILA) specified in Atlanta, replaced by ROADM
invalid node type (ILA) specified in Birmingham, replaced by ROADM
invalid node type (ILA) specified in Jacksonville, replaced by ROADM
invalid node type (ILA) specified in Houston, replaced by ROADM
invalid node type (ILA) specified in Baltimore, replaced by ROADM
invalid node type (ILA) specified in Philadelphia, replaced by ROADM
invalid node type (ILA) specified in Pittsburgh, replaced by ROADM
invalid node type (ILA) specified in Washington_DC, replaced by ROADM
invalid node type (ILA) specified in Delhi, replaced by ROADM
invalid node type (ILA) specified in Hong_Kong, replaced by ROADM
invalid node type (ILA) specified in New_Orleans, replaced by ROADM
invalid node type (ILA) specified in Warsaw, replaced by ROADM
invalid node type (ILA) specified in Billings, replaced by ROADM
invalid node type (ILA) specified in Nashville, replaced by ROADM
invalid node type (ILA) specified in Minneapolis, replaced by ROADM
invalid node type (ILA) specified in London, replaced by ROADM
invalid node type (ILA) specified in Istanbul, replaced by ROADM
invalid node type (ILA) specified in Cleveland, replaced by ROADM
invalid node type (ILA) specified in Raleigh, replaced by ROADM
invalid node type (ILA) specified in Greensboro, replaced by ROADM
invalid node type (ILA) specified in Chicago, replaced by ROADM
invalid node type (ILA) specified in Cincinnati, replaced by ROADM
invalid node type (ILA) specified in Columbus, replaced by ROADM
invalid node type (ILA) specified in Louisville, replaced by ROADM
invalid node type (ILA) specified in Mumbai, replaced by ROADM
invalid node type (ILA) specified in Omaha, replaced by ROADM
invalid node type (ILA) specified in Salt_Lake_City, replaced by ROADM
invalid node type (ILA) specified in Vienna, replaced by ROADM
invalid node type (ILA) specified in Fresno, replaced by ROADM
invalid node type (ILA) specified in Los_Angeles, replaced by ROADM
invalid node type (ILA) specified in Oakland, replaced by ROADM
invalid node type (ILA) specified in Sydney, replaced by ROADM
invalid node type (ILA) specified in Taipei, replaced by ROADM
invalid node type (ILA) specified in Honolulu, replaced by ROADM
invalid node type (ILA) specified in Rome, replaced by ROADM
invalid node type (ILA) specified in Kansas_City, replaced by ROADM
invalid node type (ILA) specified in St_Louis, replaced by ROADM
invalid node type (ILA) specified in Phoenix, replaced by ROADM
invalid node type (ILA) specified in Paris, replaced by ROADM
invalid node type (ILA) specified in Miami, replaced by ROADM
invalid node type (ILA) specified in Scranton, replaced by ROADM
invalid node type (ILA) specified in Portland, replaced by ROADM
invalid node type (ILA) specified in Tokyo, replaced by ROADM
invalid souce node specified, did you mean:
['trx Dallas']?
'dallas', replaced with trx Dallas
invalid destination node specified, did you mean:
['trx Houston']?
'houston', replaced with trx Houston

There are 4 fiber spans over 1730924m between trx Dallas and trx Houston

Now propagating between trx Dallas and trx Houston:

Propagating with input power = 0.00dBm :
Transceiver trx Dallas
Roadm roadm Dallas
loss (dB): 20.00
Edfa Edfa0_roadm Dallas
type_variety: test
gain (dB): 20.00
noise figure (dB): 6.40
Power In (dBm): -0.18
Power Out (dBm): 19.83
Fiber fiber (Dallas → Houston)-(0/4)
type_variety: SSMF
length (m): 432731.00
loss (dB): 87.55
(includes conn loss (dB) in: 0.50 out: 0.50)
Fiber fiber (Dallas → Houston)-
(1/4)
type_variety: SSMF
length (m): 432731.00
loss (dB): 87.55
(includes conn loss (dB) in: 0.50 out: 0.50)
Fiber fiber (Dallas → Houston)-(2/4)
type_variety: SSMF
length (m): 432731.00
loss (dB): 87.55
(includes conn loss (dB) in: 0.50 out: 0.50)
Fiber fiber (Dallas → Houston)-
(3/4)
type_variety: SSMF
length (m): 432731.00
loss (dB): 87.55
(includes conn loss (dB) in: 0.50 out: 0.50)
Roadm roadm Houston
loss (dB): 20.00
Transceiver trx Houston

Transmission result for input power = 0.00dBm :
Transceiver trx Houston

Elements class structure

Can we think of a better init structure than the extensive use of namedtuple we are having?
init class EDFA
I have several issues with these namedtuple. For example in the EDFA class:

  • the params parameter cannot be skipped because it will require the EDFAparams positional arguments: the None default value in init is not working by the way.
  • the params cannot be updated after the calss creation because namedtuple are unmutable. As a result I have (for example): edfa.con_in != edfa.params.con_in in some instances
  • most importantly we lost the flexiblity of the initial class structure where there was no need to update the code when adding a new parameter in the json input files. now you need to update several namedtupple and you lose compatibility with previous json files.

`load_equipment` usage in GNpy library

gnpy.core.equipment.load_equipment method is intended for eqpt_config.json file parsing and respects file structure.

Maybe it is more suitable to use it instead of direct load_SI and load_Transceiver methods in path_requests_run.py?

master:examples don't work with python3

2018-04-26
tested with python2 but got errors while python3 looks fine.

For a quick fix and to resolve ambiguity, the README file describing how to run examples in master should require be run with python3:
python3 transmission_main_example.py and
python3 transmission_main_example.py coronet_conus_example.json

are we running tests against such errors?

Note: classified as a bug since users trying to run examples but having only python2 installed will run into the issue which throws an error.


ggrammel-mbp:examples ggrammel$ python2 transmission_main_example.py
File "transmission_main_example.py", line 35
f'#{idx} Carrier(frequency={c.frequency},\n power=Power(signal={c.power.signal}, nli={c.power.nli}, ase={c.power.ase}))'
^
SyntaxError: invalid syntax

ggrammel-mbp:examples ggrammel$ python3 transmission_main_example.py
invalid souce node specified: '', replaced with Transceiver Site_A
invalid destination node specified: '', replaced with Transceiver Site_B
There are 4 network elements between Transceiver Site_A and Transceiver Site_B
Transceiver Site_A
Fiber Span1
length (m): 80000.00
loss (dB): 16.00
Edfa Edfa1
type_variety: std_low_gain
gain (dB): 16.00
noise figure (dB): 7.12
Power In (dBm): 3.83
Power Out (dBm): 19.83
Transceiver Site_B
OSNR ASE (1nm): 34.83
OSNR ASE (signal bw): 30.75
SNR total (signal bw): 27.36
ggrammel-mbp:examples ggrammel$

Suggested improvement of README

2018-07-21

README:

  • installation from repo OK
  • set PYTHONPATH variable as described. Consider moving the text in front of example:
    “You may need to set PYTHONPATH variable. For example on Ubuntu, add your workspace path to PYTHONPATH in your .bashrc file:
    export PYTHONPATH=$PYTHONPATH:~//gnpy/“

Issue from Bell labs

Following-up an email from a collegue at Bell labs, I've given some instructions on how to download
gnpy. Then, I've received the e-mail message I'm posting in the following. In my opinion, the arised issues may be of general interest, and it could be worth to discuss them.
Vittorio

One of my managers followed your instructions for downloading and running the tool. He had the following questions and issues:

  1. There is very little if any documentation on the website. Can you point to any documentation?
  2. He could find no description of the various Tx/Rx types that can be simulated.
  3. There is nothing about the constellation.
  4. He asked if you have a model of m-QAM modulation that he can try out.

json file for ofc demo

I have adapted network.py by writing new subs 'split_fiber' and 'add_egress_amplifier' to handle the coronet.conus network. It's now working, finding a path and displaying results (over 144 nodes!) (and ~10dB SNR in 0.1nm bandwidth)
=> just need to do a bit of checking (and do a proper fiber length split) and present the results more nicely.
=> we need a network graph too: if someone could volunteer to code it in transmission_main_example.py? (I have no graphic skills ;)

ROADM loss

At the moment development version for ROADMs has only one loss parameter and from example can be understood that this is express channel loss (Preamp -> filter_structure -> Booster).

If Transceiver is defined in ROADM network element (parsed .xls) its transmit power is attenuated by this express_loss and that influences Booster type and its amplification target.

Practically there are at least two types of losses:

  • express channel loss ("Preamp -> filter_structure -> Booster")
  • add/drop channel loss ("filter_structure -> Booster" and "Preamp -> filter_structure")

Additionally it will usable to use Booster-less amplifiers (#62).

dbkm_2_lin error

in the class Fiber,the bounded method def dbkm_2_lin(self):.... may be error. the linear alpha = (nonlinear alpha)/10/log10(e)(1/km),

Create a portable version of the tool

In order to have the software tested by non-developper colleagues (ie who will not have to install python3.6 and fix all issues related to import modules packages), it could be interesting to have a portable version (an executable?) of it + a guideline to create one.
I have tried with Cx_Freeze without success...
(the executable fails to execute although cxfreeze compiles successfully)

EDFA parameters and booster-less type

It will be convenient to enter EDFA parameters closer to the defined by the equipment configuration. Our equipment vendor uses two types of config for different system types:

  1. Without OSC channel
    1.1 Gain (already implemented)

  2. With OSC channel
    2.1 Filter structure output power (target channel power before amplification - at amp input, and is frequency dependent)
    2.2 Booster and Preamplifier Po/ch (target channel power after amplification - at amp output)
    2.3 Booster-less amplifier (OSC channel termination)

In second case Booster Gain can be calculated from entered parameters (2.2 and 2.1) and Preamp Gain from line input power against target power (2.2). Both parameters are dependent from particular ROADM direction goals, so each direction and one directions Booster/Preamp can use its own.

For short spans 2.3 amplifier type can be used, in that case amplifier is just attenuation source.

Edit:
2.1 definition

plot feature does not seem to work in every cases on transmission_main_example.py

When trying -p option on develop branch, it does not work for meshTopologyExampleV2.xls or json, CORONET_Global_Topology.xls or json
It works with the edfa_example_network.json

python3 transmission_main_example.py -p meshTopologyExampleV2.xls 'trx Lannion_CAS' 'trx Lorient_KMA'
There are 3 fiber spans over 130000m between trx Lannion_CAS and trx Lorient_KMA
Now propagating between trx Lannion_CAS and trx Lorient_KMA:
Porpagating with input power = 0.00dBm :
Transceiver trx Lannion_CAS
Roadm roadm Lannion_CAS
loss (dB): 20.00
Edfa Edfa0_roadm Lannion_CAS
type_variety: test
gain (dB): 20.00
noise figure (dB): 6.40
Power In (dBm): -0.18
Power Out (dBm): 19.83
Fiber fiber (Lannion_CAS → Corlay)-F061
type_variety: SSMF
length (m): 20000.00
loss (dB): 4.00
Fused ingress fused spans in Corlay
loss (dB): 1.00
Fiber fiber (Corlay → Loudeac)-F010
type_variety: SSMF
length (m): 50000.00
loss (dB): 10.00
Fused ingress fused spans in Loudeac
loss (dB): 1.00
Fiber fiber (Loudeac → Lorient_KMA)-F054
type_variety: SSMF
length (m): 60000.00
loss (dB): 12.00
Edfa Edfa0_fiber (Loudeac → Lorient_KMA)-F054
type_variety: std_medium_gain
gain (dB): 28.00
noise figure (dB): 5.97
Power In (dBm): -8.17
Power Out (dBm): 19.88
Roadm roadm Lorient_KMA
loss (dB): 20.00
Transceiver trx Lorient_KMA
OSNR ASE (1nm): 23.27
OSNR ASE (signal bw): 19.19
SNR total (signal bw): 19.03

Transmission result for input power = 0.00dBm :
Transceiver trx Lorient_KMA
OSNR ASE (1nm): 23.27
OSNR ASE (signal bw): 19.19
SNR total (signal bw): 19.03
Traceback (most recent call last):
File "transmission_main_example.py", line 141, in
plot_results(network, path, source, sink)
File "transmission_main_example.py", line 30, in plot_results
pos = {n: (n.lng, n.lat) for n in network.nodes()}
File "transmission_main_example.py", line 30, in
pos = {n: (n.lng, n.lat) for n in network.nodes()}
File "/home/user/workspace/TIP/gnpy/gnpy/core/node.py", line 47, in longitude
return self.location.longitude
File "/home/user/workspace/TIP/gnpy/gnpy/core/node.py", line 42, in location
return self.metadata['location']
TypeError: 'NoneType' object is not subscriptable

Missing License file

ACTION required
License file is missing and need to be added ASAP.

The only repository with a License file is "Phase-1" but Phase-1 is not supposed to be carried-on. All other repositories shall be equipped with a correct LICENSE file.

The issue has been reported and assigned in the coders call Nov-22 and Nov-28 for action

Fiber designations and parameters library

I'm filling in the model spreadsheet with info for the NYSERNet network and have come up with a few comments and questions. This one isn't specific to the spreadsheet though, so I'm separating it out.

I think we should standardize on a list of fiber names and build a library of common types. I have both Corning LEAF (which could be called NZDSF or G.655) and generic SMF-28 (which could also be called SMF, SSMF, or G.652). Other networks would likely have one or both of those types, but could have specific manufacturers' products as well, with somewhat different characteristics.

There's also a question in my mind about how precise our fiber parameters will be, and whether it's good to have specific manufacturer numbers or just generic, and therefore approximate values. I think there should also be a simple mechanism for adding new fiber types, which is one of the reasons I suggest making this a specific data store rather than burying it in the code.

Readme test: Following description produces failures

The aim is to run through Readme.md and check if it sufficiently describes the necessary steps to run the code. The Description SHALL be fixed before it goes in main branch.
There is extensive output in the description aiming to ease debugging. For a quick check look for the keyword FAIL

  1. Before starting:
    env:
    TERM_PROGRAM=Apple_Terminal SHELL=/bin/bash TERM=xterm-256color TMPDIR=/var/folders/zk/gn06x9b11pn8ddjrg680m3jm0000gn/T/ Apple_PubSub_Socket_Render=/private/tmp/com.apple.launchd.a6XnPXL9wL/Render TERM_PROGRAM_VERSION=388.1.2 OLDPWD=/projects/github TERM_SESSION_ID=89B74D31-1873-4E10-A1A3-10CA5C037D68 USER=ggrammel SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.WwB0iI5iBx/Listeners __CF_USER_TEXT_ENCODING=0x1F5:0x0:0x0 PATH=/anaconda3/bin:/Library/Frameworks/Python.framework/Versions/3.6/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin PWD=/projects/github/testing LANG=en_US.UTF-8 XPC_FLAGS=0x0 XPC_SERVICE_NAME=0 SHLVL=1 HOME=/Users/ggrammel LOGNAME=ggrammel _=/usr/bin/env
    $PWD
    /projects/github/testing
    $PYTHONPATH
    empty

  2. installation:
    2.1 using the first option
    2.1.1 pip3 install gnpy' --> **SUCCESS**
    pip3 install gnpy
    Requirement already satisfied: gnpy in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (0.1.3)
    Requirement already satisfied: py==1.5.2 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.5.2)
    Requirement already satisfied: numpy==1.13.3 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.13.3)
    Requirement already satisfied: pybtex==0.21 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.21)
    Requirement already satisfied: Jinja2==2.10 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.10)
    Requirement already satisfied: matplotlib==2.1.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.1.0)
    Requirement already satisfied: imagesize==0.7.1 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.7.1)
    Requirement already satisfied: requests==2.18.4 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.18.4)
    Requirement already satisfied: networkx==2.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.0)
    Requirement already satisfied: pytest==3.3.2 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (3.3.2)
    Requirement already satisfied: decorator==4.1.2 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (4.1.2)
    Requirement already satisfied: scipy==1.0.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.0.0)
    Requirement already satisfied: snowballstemmer==1.2.1 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.2.1)
    Requirement already satisfied: six==1.11.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.11.0)
    Requirement already satisfied: chardet==3.0.4 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (3.0.4)
    Requirement already satisfied: pluggy==0.6.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.6.0)
    Requirement already satisfied: idna==2.6 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.6)
    Requirement already satisfied: Babel==2.5.3 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.5.3)
    Requirement already satisfied: xlrd==1.1.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.1.0)
    Requirement already satisfied: MarkupSafe==1.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.0)
    Requirement already satisfied: PyYAML==3.12 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (3.12)
    Requirement already satisfied: sphinxcontrib-websupport==1.0.1 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.0.1)
    Requirement already satisfied: certifi==2017.11.5 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2017.11.5)
    Requirement already satisfied: pybtex-docutils==0.2.1 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.2.1)
    Requirement already satisfied: pyparsing==2.2.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.2.0)
    Requirement already satisfied: urllib3==1.22 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.22)
    Requirement already satisfied: alabaster==0.7.10 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.7.10)
    Requirement already satisfied: Sphinx==1.6.6 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.6.6)
    Requirement already satisfied: oset==0.1.3 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.1.3)
    Requirement already satisfied: Pygments==2.2.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.2.0)
    Requirement already satisfied: python-dateutil==2.6.1 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2.6.1)
    Requirement already satisfied: cycler==0.10.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.10.0)
    Requirement already satisfied: attrs==17.4.0 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (17.4.0)
    Requirement already satisfied: docutils==0.14 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.14)
    Requirement already satisfied: latexcodec==1.0.5 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (1.0.5)
    Requirement already satisfied: sphinxcontrib-bibtex==0.3.6 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (0.3.6)
    Requirement already satisfied: pytz==2017.3 in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from gnpy) (2017.3)
    Requirement already satisfied: setuptools in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from pytest==3.3.2->gnpy) (38.5.1)
    `
    2.1.2 skipping alternative installation procedure and continuing with 'To get started, run the transmission example:'

2.1.3 running transmission example --> FAIL
cd examples -bash: cd: examples: No such file or directory
setup.py did not create the examples directory and the procedure described is not operational. Suggestion is to remove it from the description

2.2 performing the alternative procedure using the repo

2.2.1 Cloning oopt-gnpy --> SUCCESS
NOTE since we are testing the develop branch, git clone... needs to be modified as below
git clone --single-branch -b develop https://github.com/telecominfraproject/oopt-gnpy/ Cloning into 'oopt-gnpy'... remote: Counting objects: 1521, done. remote: Compressing objects: 100% (101/101), done. remote: Total 1521 (delta 104), reused 116 (delta 68), pack-reused 1352 Receiving objects: 100% (1521/1521), 676.45 KiB | 563.00 KiB/s, done. Resolving deltas: 100% (939/939), done.
2.2.2 change directory --> SUCCESS
cd oopt-gnpy

2.2.3 install oopt-gnpy --> SUCCESS
`python3 setup.py install
/anaconda3/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
warnings.warn(msg)
running install
running bdist_egg
running egg_info
creating gnpy.egg-info
writing gnpy.egg-info/PKG-INFO
writing dependency_links to gnpy.egg-info/dependency_links.txt
writing requirements to gnpy.egg-info/requires.txt
writing top-level names to gnpy.egg-info/top_level.txt
writing manifest file 'gnpy.egg-info/SOURCES.txt'
reading manifest file 'gnpy.egg-info/SOURCES.txt'
writing manifest file 'gnpy.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-10.7-x86_64/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/gnpy
copying gnpy/init.py -> build/lib/gnpy
creating build/lib/gnpy/core
copying gnpy/core/init.py -> build/lib/gnpy/core
copying gnpy/core/convert.py -> build/lib/gnpy/core
copying gnpy/core/elements.py -> build/lib/gnpy/core
copying gnpy/core/equipment.py -> build/lib/gnpy/core
copying gnpy/core/execute.py -> build/lib/gnpy/core
copying gnpy/core/info.py -> build/lib/gnpy/core
copying gnpy/core/network.py -> build/lib/gnpy/core
copying gnpy/core/node.py -> build/lib/gnpy/core
copying gnpy/core/request.py -> build/lib/gnpy/core
copying gnpy/core/units.py -> build/lib/gnpy/core
copying gnpy/core/utils.py -> build/lib/gnpy/core
creating build/bdist.macosx-10.7-x86_64
creating build/bdist.macosx-10.7-x86_64/egg
creating build/bdist.macosx-10.7-x86_64/egg/gnpy
copying build/lib/gnpy/init.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy
creating build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/init.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/convert.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/elements.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/equipment.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/execute.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/info.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/network.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/node.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/request.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/units.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
copying build/lib/gnpy/core/utils.py -> build/bdist.macosx-10.7-x86_64/egg/gnpy/core
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/init.py to init.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/init.py to init.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/convert.py to convert.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/elements.py to elements.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/equipment.py to equipment.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/execute.py to execute.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/info.py to info.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/network.py to network.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/node.py to node.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/request.py to request.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/units.py to units.cpython-36.pyc
byte-compiling build/bdist.macosx-10.7-x86_64/egg/gnpy/core/utils.py to utils.cpython-36.pyc
creating build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
copying gnpy.egg-info/PKG-INFO -> build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
copying gnpy.egg-info/SOURCES.txt -> build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
copying gnpy.egg-info/dependency_links.txt -> build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
copying gnpy.egg-info/requires.txt -> build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
copying gnpy.egg-info/top_level.txt -> build/bdist.macosx-10.7-x86_64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating dist
creating 'dist/gnpy-0.1.3-py3.6.egg' and adding 'build/bdist.macosx-10.7-x86_64/egg' to it
removing 'build/bdist.macosx-10.7-x86_64/egg' (and everything under it)
Processing gnpy-0.1.3-py3.6.egg
Removing /anaconda3/lib/python3.6/site-packages/gnpy-0.1.3-py3.6.egg
Copying gnpy-0.1.3-py3.6.egg to /anaconda3/lib/python3.6/site-packages
gnpy 0.1.3 is already the active version in easy-install.pth

Installed /anaconda3/lib/python3.6/site-packages/gnpy-0.1.3-py3.6.egg
Processing dependencies for gnpy==0.1.3
Searching for xlrd==1.1.0
Best match: xlrd 1.1.0
Adding xlrd 1.1.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for urllib3==1.22
Best match: urllib3 1.22
Adding urllib3 1.22 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for sphinxcontrib-websupport==1.0.1
Best match: sphinxcontrib-websupport 1.0.1
Adding sphinxcontrib-websupport 1.0.1 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for sphinxcontrib-bibtex==0.3.6
Best match: sphinxcontrib-bibtex 0.3.6
Processing sphinxcontrib_bibtex-0.3.6-py3.6.egg
sphinxcontrib-bibtex 0.3.6 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/sphinxcontrib_bibtex-0.3.6-py3.6.egg
Searching for Sphinx==1.6.6
Best match: Sphinx 1.6.6
Processing Sphinx-1.6.6-py3.6.egg
Sphinx 1.6.6 is already the active version in easy-install.pth
Installing sphinx-apidoc script to /anaconda3/bin
Installing sphinx-autogen script to /anaconda3/bin
Installing sphinx-build script to /anaconda3/bin
Installing sphinx-quickstart script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages/Sphinx-1.6.6-py3.6.egg
Searching for snowballstemmer==1.2.1
Best match: snowballstemmer 1.2.1
Adding snowballstemmer 1.2.1 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for six==1.11.0
Best match: six 1.11.0
Adding six 1.11.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for scipy==1.0.0
Best match: scipy 1.0.0
Processing scipy-1.0.0-py3.6-macosx-10.7-x86_64.egg
scipy 1.0.0 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/scipy-1.0.0-py3.6-macosx-10.7-x86_64.egg
Searching for requests==2.18.4
Best match: requests 2.18.4
Adding requests 2.18.4 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for PyYAML==3.12
Best match: PyYAML 3.12
Adding PyYAML 3.12 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for pytz==2017.3
Best match: pytz 2017.3
Processing pytz-2017.3-py3.6.egg
pytz 2017.3 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/pytz-2017.3-py3.6.egg
Searching for python-dateutil==2.6.1
Best match: python-dateutil 2.6.1
Processing python_dateutil-2.6.1-py3.6.egg
python-dateutil 2.6.1 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/python_dateutil-2.6.1-py3.6.egg
Searching for pytest==3.3.2
Best match: pytest 3.3.2
Processing pytest-3.3.2-py3.6.egg
pytest 3.3.2 is already the active version in easy-install.pth
Installing py.test script to /anaconda3/bin
Installing pytest script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages/pytest-3.3.2-py3.6.egg
Searching for pyparsing==2.2.0
Best match: pyparsing 2.2.0
Adding pyparsing 2.2.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for Pygments==2.2.0
Best match: Pygments 2.2.0
Adding Pygments 2.2.0 to easy-install.pth file
Installing pygmentize script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages
Searching for pybtex-docutils==0.2.1
Best match: pybtex-docutils 0.2.1
Processing pybtex_docutils-0.2.1-py3.6.egg
pybtex-docutils 0.2.1 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/pybtex_docutils-0.2.1-py3.6.egg
Searching for pybtex==0.21
Best match: pybtex 0.21
Processing pybtex-0.21-py3.6.egg
pybtex 0.21 is already the active version in easy-install.pth
Installing pybtex script to /anaconda3/bin
Installing pybtex-convert script to /anaconda3/bin
Installing pybtex-format script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages/pybtex-0.21-py3.6.egg
Searching for py==1.5.2
Best match: py 1.5.2
Processing py-1.5.2-py3.6.egg
py 1.5.2 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/py-1.5.2-py3.6.egg
Searching for pluggy==0.6.0
Best match: pluggy 0.6.0
Adding pluggy 0.6.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for oset==0.1.3
Best match: oset 0.1.3
Processing oset-0.1.3-py3.6.egg
oset 0.1.3 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/oset-0.1.3-py3.6.egg
Searching for numpy==1.13.3
Best match: numpy 1.13.3
Processing numpy-1.13.3-py3.6-macosx-10.7-x86_64.egg
numpy 1.13.3 is already the active version in easy-install.pth
Installing f2py script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages/numpy-1.13.3-py3.6-macosx-10.7-x86_64.egg
Searching for networkx==2.0
Best match: networkx 2.0
Processing networkx-2.0-py3.6.egg
networkx 2.0 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/networkx-2.0-py3.6.egg
Searching for matplotlib==2.1.0
Best match: matplotlib 2.1.0
Processing matplotlib-2.1.0-py3.6-macosx-10.7-x86_64.egg
matplotlib 2.1.0 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/matplotlib-2.1.0-py3.6-macosx-10.7-x86_64.egg
Searching for MarkupSafe==1.0
Best match: MarkupSafe 1.0
Adding MarkupSafe 1.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for latexcodec==1.0.5
Best match: latexcodec 1.0.5
Processing latexcodec-1.0.5-py3.6.egg
latexcodec 1.0.5 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/latexcodec-1.0.5-py3.6.egg
Searching for Jinja2==2.10
Best match: Jinja2 2.10
Adding Jinja2 2.10 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for imagesize==0.7.1
Best match: imagesize 0.7.1
Processing imagesize-0.7.1-py3.6.egg
imagesize 0.7.1 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/imagesize-0.7.1-py3.6.egg
Searching for idna==2.6
Best match: idna 2.6
Adding idna 2.6 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for docutils==0.14
Best match: docutils 0.14
Adding docutils 0.14 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for decorator==4.1.2
Best match: decorator 4.1.2
Processing decorator-4.1.2-py3.6.egg
decorator 4.1.2 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/decorator-4.1.2-py3.6.egg
Searching for cycler==0.10.0
Best match: cycler 0.10.0
Adding cycler 0.10.0 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for chardet==3.0.4
Best match: chardet 3.0.4
Adding chardet 3.0.4 to easy-install.pth file
Installing chardetect script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages
Searching for certifi==2017.11.5
Best match: certifi 2017.11.5
Processing certifi-2017.11.5-py3.6.egg
certifi 2017.11.5 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/certifi-2017.11.5-py3.6.egg
Searching for Babel==2.5.3
Best match: Babel 2.5.3
Adding Babel 2.5.3 to easy-install.pth file
Installing pybabel script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages
Searching for attrs==17.4.0
Best match: attrs 17.4.0
Processing attrs-17.4.0-py3.6.egg
attrs 17.4.0 is already the active version in easy-install.pth

Using /anaconda3/lib/python3.6/site-packages/attrs-17.4.0-py3.6.egg
Searching for alabaster==0.7.10
Best match: alabaster 0.7.10
Adding alabaster 0.7.10 to easy-install.pth file

Using /anaconda3/lib/python3.6/site-packages
Searching for setuptools==39.1.0
Best match: setuptools 39.1.0
Adding setuptools 39.1.0 to easy-install.pth file
Installing easy_install script to /anaconda3/bin

Using /anaconda3/lib/python3.6/site-packages
Finished processing dependencies for gnpy==0.1.3
'

2.2.4 change directory --> SUCCESS
cd examples

2.2.5 trying Transmission_main_example --> FAIL
python3 transmission_main_example.py Traceback (most recent call last): File "transmission_main_example.py", line 23, in <module> from gnpy.core.request import Path_request, RequestParams, compute_constrained_path, propagate File "/anaconda3/lib/python3.6/site-packages/gnpy-0.1.3-py3.6.egg/gnpy/core/request.py", line 22, in <module> ModuleNotFoundError: No module named 'examples'
this error could have been avoided by informing the user about setting PYTHONPATH prior to suggesting running the example

  1. Re-trying by setting PYTHONPATH
    export PYTHONPATH=$PYTHONPATH:$PWD $ echo $PYTHONPATH :/projects/github/testing/oopt-gnpy
    3.1 change directory --> SUCCESS
    'cd examples`

3.2 running transmission_main_example --> SUCCESS
`
python3 transmission_main_example.py
Power mode is set to True
=> it can be modified in eqpt_config.json - Spans
Transceiver(uid='Site_B', osnr_ase_01nm=None, osnr_ase=None, osnr_nli=None, snr=None) delta power in:
-3dB

There are 1 fiber spans over 80000m between Site_A and Site_B

Now propagating between Site_A and Site_B:
[0]

Propagating with input power = 0.00dBm :
Transceiver Site_A
Fiber Span1
type_variety: SSMF
length (km): 80.00
pad att_in (dB): 0.00
total loss (dB): 16.00
(includes conn loss (dB) in: 0.00 out: 0.00)
(conn loss out includes EOL margin defined in eqpt_config.json)
Edfa Edfa1
type_variety: std_low_gain
target gain (dB): 16.00
effective gain(dB): 16.00
noise figure (dB): 6.57
including att_in
pad att_in (dB): 0.00
Power In (dBm): 2.81
Power Out (dBm): 18.82
Delta_P (dB): 0.0
target pch (dBm): 0.0
effective pch (dBm): 0.0
output VOA (dB): 0.00
Transceiver Site_B
OSNR ASE (1nm): 35.38
OSNR ASE (signal bw): 31.30
SNR total (signal bw): 27.71

Transmission result for input power = 0.00dBm :
Transceiver Site_B
OSNR ASE (1nm): 35.38
OSNR ASE (signal bw): 31.30
SNR total (signal bw): 27.71
`
3.3 running Coronet example --> FAIL
'
python3 transmission_main_example.py coronet_conus_example.json
Traceback (most recent call last):
File "transmission_main_example.py", line 108, in
network = load_network(args.filename, equipment)
File "/projects/github/testing/oopt-gnpy/gnpy/core/network.py", line 36, in load_network
json_data = load_json(json_filename)
File "/projects/github/testing/oopt-gnpy/gnpy/core/utils.py", line 20, in load_json
with open(filename, 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: 'coronet_conus_example.json'
'

checking directory content of ./examples shows that there is no coronet_conus_example. json present:
ls CORONET_Global_Topology.json eqpt_config.json CORONET_Global_Topology.xls fused_roadm_example_network.json Transmission Main Example.ipynb meshTopologyExampleV2.json __pycache__ meshTopologyExampleV2.xls convert_service_sheet.py meshTopologyExampleV2_services.json create_eqpt_sheet.py path_requests_run.py default_edfa_config.json std_medium_gain_advanced_config.json edfa transmission_main_example.py edfa_example_network.json write_path_jsontocsv.py edfa_model
Note: the name may have been changed to CORONET_Global_Topology.json and we give this a try:
transmission_main_example.py CORONET_Global_Topology.json Power mode is set to True ...
*Note: Readme shall be updated to reflect new filename

3.4 Running next example -->FAIL
python path_requests_run.py meshTopologyExampleV2.xls meshTopologyExampleV2_services.json eqpt_file -o output_file.json Traceback (most recent call last): File "path_requests_run.py", line 133, in <module> equipment = load_equipment(args.eqpt_filename) File "/projects/github/testing/oopt-gnpy/gnpy/core/equipment.py", line 194, in load_equipment json_data = load_json(filename) File "/projects/github/testing/oopt-gnpy/gnpy/core/utils.py", line 20, in load_json with open(filename, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'eqpt_file'

**NOTE: "eqpt_file" seems to be a parameter description, but this is not clear. Replacing it by eqpt_config.json in examples is successful.
python path_requests_run.py meshTopologyExampleV2.xls meshTopologyExampleV2_services.json eqpt_config.json -o output_file.json [Path_request 0 source: trx Lorient_KMA destination: trx Vannes_KBE trx type: Voyager_16QAM baud_rate: 32000000000.0 spacing: 50000000000.0 power: 0.0012589254117941673 , Path_request 1 source: trx Brest_KLA destination: trx Vannes_KBE trx type: Voyager_16QAM baud_rate: 32000000000.0 ...

testing installation: error

running through installation as described in Readme on 2018-04-16 on my Mac:

pip3 install gnpy --> works

Traceback (most recent call last):
ggrammel-mbp:gnpy ggrammel$ python examples/transmission_main_example.py
File "examples/transmission_main_example.py", line 106, in
exit(main(args))
File "examples/transmission_main_example.py", line 41, in main
network = network_from_json(json_data)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/network.py", line 29, in network_from_json
g.add_node(getattr(elements, el_config['type'])(el_config))
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/gnpy/core/elements.py", line 111, in init
self.dispersion = self.params.dispersion #s/m/m
AttributeError: 'ConfigStruct' object has no attribute 'dispersion'

Excel questions and observations

This is the list of questions and observations I've come up with while putting the NYSERNet network into the Excel input format:

Nodes:

  • I don't know what "Region" means.

Links page:

  • For each of my spans, I know the end-to-end loss, but not the loss per km. It's obviously trivial to calculate one from the other, but I think it would be easiest to enter the information as end-to-end loss.
  • I am not sure what's being asked for in the PMD column: characteristic PMD measurement for the fiber (which should come from the fiber data) or measured/calculated PMD for the link. I don't have the ability to measure PMD so I can't report that in any case.
  • I'm not sure what "SRG interest" refers to.

exception occured running transmission_main_example in anaconda/spyder

2018-08-01
Installing gnpy in Anaconda. Then navigating to examples directory and starting transmission_main_example.py from the toolbar creates the following output in IPython, throwing an exception:

runfile('/projects/github/testing/gnpy/examples/transmission_main_example.py', wdir='/projects/github/testing/gnpy/examples')
    invalid souce node specified: '', replaced with Transceiver Site_A
    invalid destination node specified: '', replaced with Transceiver Site_B
    There are 4 network elements between Transceiver Site_A and Transceiver Site_B
    Transceiver Site_A
    Fiber Span1
      length (m): 80000.00
      loss (dB):  16.00
    Edfa Edfa1
      type_variety:      std_low_gain
      gain (dB):         16.00
      noise figure (dB): 7.12
      Power In (dBm):    3.83
      Power Out (dBm):   19.83
    Transceiver Site_B
      OSNR ASE (1nm):        34.83
      OSNR ASE (signal bw):  30.75
      SNR total (signal bw): 27.36
    An exception has occurred, use %tb to see the full traceback.

    SystemExit

    /anaconda3/lib/python3.6/site-packages/IPython/core/interactiveshell.py:2971: UserWarning: To exit: use 'exit', 'quit', or Ctrl-D.
      warn("To exit: use 'exit', 'quit', or Ctrl-D.", stacklevel=1)

looks like some explicit exit statement is required. Since the use of Anaconda is recommended, the issue should be fixed before updating master.

__main__.py: ImportError: cannot import name 'network_from_json'

Trying to run __main__.py from proposal_network_architecture but ends up with an error:

$ python __main__.py
Traceback (most recent call last):
  File "__main__.py", line 15, in <module>
    from . import network_from_json
ImportError: cannot import name 'network_from_json'

Excel User Guide improvements

2018-07-21

Excel_userguide.rst:

  • Line 14: The file meshTopologyExampleV2 contains also a tab “service” while the text only says:
    (In progress) The File MAY contain an additional sheet:

  • Eqt

  • Line 26: Questions about the following text:
    City is used for the name of a node of the digraph. It accepts letters, numbers,commas,underscore,dash, blank... (not exhaustive).

    • often CSV is used as format. Suggestion is to disallow a comma for any entry in the table
    • should it be called “diagram” other than “digraph”?
  • line 54: unclear what this means:
    'z to a' direction MUST NOT be repeated in a different line.

  • line 33: typo s/fuesed/fused

  • line 79: should explain why, e.g.: “if amplifier sites are unknown, spans need to be broken up. The current assumption is that links larger than 150km will require intermediate amplification. This assumption will be revisited when Raman amplification is added”

  • line 105: add “… and shall be unique”.

  • line 116: appears to me that only 12 columns are used

  • line 121: The text says:
    If the sheet is present, it MUST have as many lines as egress directions of ROADMs defined in Links Sheet.

    • the later example contains more lines (ILA to ILA connections). does it mean those ILA2ILA lines are optional?
  • line 146: How does the code help? A little more description is useful:

    • create_eqpt_sheet.py <examples/create_eqpt_sheet.py>_ helps you to create a template for the mandatory entries of the list.
  • Question to line 193: Since TRX types are mandatory input parameters, they have to be manually pre-selected. Would be good to be able to put here a “most-sensitive” wildcard, which would provide the highest modulation scheme supporting the service. This may require that the list of TXP is sequenced, i.e. it may be preferable to use a 400G TXP with 1dBm output power over one with 4dBm output power.

  • line 239: an example and the interpretation of the output would help to interpret this output:
    Computing path from trx Brest_KLA to trx Vannes_KBE
    with explicit path: ['Lannion_CAS', 'Lorient_KMA', 'trx Vannes_KBE']
    pi -8.0
    pi -5.0
    pi -17.0

  • line 246: the description is unclear
    Important note: path_requests_run.py is not a dimensionning tool, it only computes path feasibility assuming full load with system parameters input in the service file.

    • we do not have a definition of “dimensioning tool”. Some additional text may help.
    • what means “full load” as the service file describes a partial load (i.e. the services) in the network?
      The network topology is created only once for the set of requests.
    • which “topology” is meant? the fiber topology should be clear from the beginning. I believe it means the “wavelength routes”.
      As a result the transceiver element acts as a "logical starting/stopping point" for the spectral information propagation. At that point it is not meant to represent the capacity of add drop ports
    • what does it mean to say “not meant to represent the capacity …”? Perhaps an issue because of the PCE model, but it confused me as there is no precedent where capacity is mentioned.
      As a result transponder type is not part of the network info. it is related to the list of services requests.
    • I would rather call it “connectivity demand” as “services” may require more information.

some typos in example/convert.py

I can not execute convert.py and found some typos : some 'f' characters on lines 26, 36, 45, 48, 88, 96, 88 eg: ValueError(f' ...') are not supported by my python and line numbers are not correct on lines 23 and 33 : should be 4 instead of 5 since header is on line 4 in the excel file example (starting numbering from 0)

'network_from_json' is not defined

running python3 -m core from the root directory of proposal_network_architecture generates a name error:

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/projects/github/gnpy/core/__main__.py", line 117, in <module>
    exit(main(args))
  File "/projects/github/gnpy/core/__main__.py", line 38, in main
    network = network_from_json(json_data)
NameError: name 'network_from_json' is not defined

lin_loss _coeff error

image

i think this may be wrong
self.lin_loss_coef = self.params.loss_coef / (20np.log10(np.exp(1)))
correct should be:
self.lin_loss_coef = self.params.loss_coef / (10
np.log10(np.exp(1)))

edfa model work

on going work on my side to refine the edfa model,
to begin with:
-correction of the previous issue
-json input file to centralize all amplifiers data (type, gain-max, p_max, nf_fit polynoms & models, nf_ripple_96, dgt, ...)
-nf model in case the nf polynomial fit is not available (there is a tag true/false in the json file)
-pytest module to validate the code (based on a simple OSNR check)

Examples in main do not produce graphical output anymore

trying out the Examples (after having applied workaround reported before on the README file) it turns out that the graphical output is not available anymore. The previous master did produce a window with a graphical representation of the network. The current master only produces text output.

Lunching develop branch from binder

throwing Error message:
"cannot uninstall 'certifi'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall"

Note: The use of binder is nowhere described in our readme and it is not clear why binder is needed at all. It looks like it creates more hassle than needed and gnpy is not really maintained to run in that environment. Suggest to remove it for now and focus on a good description based on shell commands

Coronet example throws errors

  • Coronet did not work:
    ggrammel-mbp:examples ggrammel$ python3 transmission_main_example.py coronet_conus_example.json
    coronet_conus_example.json
    Traceback (most recent call last):
    File "transmission_main_example.py", line 102, in
    network = load_network(args.filename, equipment)
    File "/projects/github/test/oopt-gnpy-develop/gnpy/core/network.py", line 32, in load_network
    return network_from_json(json_data, equipment)
    File "/projects/github/test/oopt-gnpy-develop/gnpy/core/network.py", line 46, in network_from_json
    el = cls(**el_config)
    File "/projects/github/test/oopt-gnpy-develop/gnpy/core/elements.py", line 168, in init
    super().init(*args, params=FiberParams(**params), **kwargs)
    TypeError: new() missing 1 required positional argument: 'type_variety'

venv and anaconda

Current Readme says:
"It is recommended that you use a virtual environment when installing from the repo. In Python 3, you can use the venv module.

Note: Alternatively, we recommend the use of the Anaconda Python distribution (https://www.anaconda.com/download) which comes with many scientific computing dependencies pre-installed."

clearly gnpy does not have to describe how to use them, but if there are particular needs to make the code run smoothly in those environments it should be described.

To run transmission_main_example.py in SPYDER

  1. --> python --> PYTHONPATH manager (Add path)
    /oopt-gnpy

  2. --> python --> Preferences --> Run
    Default working directory is:
    "the following directory: /oopt

After that open "transmission_main_example_py" in the editor pane and run by either clicking on the green triangle "run".

alternatively if you want to use the Python console on the bottom right
cd <mypath>/OOPT-gnpy/examples %run transmission_main_example.py

gnpy-gui interface and framework

It will be great to have GNS3 like interface with according icons of elements, GNPY model already defines elements stand-alone like. In that case network could be imported from JSON/XLS.

Does this project is planning to introduce GUI interface?
What kind of framework would be preferred?

gnpy doesn't work after the installation

  • gnpy version: 0.1.0
  • Python version: 2.7.13 and 3.6.1
  • Operating System: Fedora 26

Description

What I Did

I installed gnpy using python 2.7.13 with the command
sudo python setup.py clean build -f install
then I run the program with the command
gnpy
and the output is the following;

Replace this message by putting your code into gnpy.cli.main
See click documentation at http://click.pocoo.org/

I tried also using python3 but the output is the same

example folder needs cleanup

checked example folder and wondered about a few details:

  • we have EDFA and EDFA model which seem to include similar but nt the same files. both are 5month old. do we really need both? which one is the correct one?

  • taking edfa_model DFG_96.txt as an example: when clicking on it, it is shown as executable. This is strange for a text file and indeed it does not include code at all. Other .txt files are the same (I did not check all of them)

why do we need https://github.com/Telecominfraproject/oopt-gnpy/blob/develop/examples/Transmission%20Main%20Example.ipynb is anybody using it?

https://github.com/Telecominfraproject/oopt-gnpy/blob/develop/examples/std_medium_gain_advanced_config.json is located in examples but I wonder if that's the right place. Amplifiers are typically composed of EDFAs and those are in other folders. It's confusing to find it here.

edfa model

Playing with the code, I found a unit issue at line 56 in amplifier.py:
h_mWThz should write 1e3xhx(1e12)xx2 and not 1e-3xhx(1e14)xx2
The above modification gives the expected ASE noise levels.

fix docs at gnpy.readthedocs.io

Module-level and function-level documentation is missing on gnpy.readthedocs.io

Fix this to include both module-level and function-level Sphinx documentation.

installing gnpy option doesn't allow to follow rest of readme

2018-08-01
Readme says:
gnpy is hosted in the Python Package Index (gnpy). It can be installed via:
$ pip3 install gnpy
This will install the current (tagged) release version.

further down, Readme then continues with:
To get started, run the transmission example:
Note: Examples should be run from the examples/ folder.
$ cd examples
$ python transmission_main_example.py

However if gnpy was installed with pip3, there is no "examples" directory.

Simple fix would be to remove the first statement from Readme and only leave the "Alternative" way to install for now.
Another possibility is to add verbiage about requiring the alternative installation procedure to run through the examples.

labeled as bug in Readme, no code changes needed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.