Critical-Infrastructure-Systems-Lab / DHALSIM

Digital Twin for Water Distribution Systems. A work by the SUTD Critical Infrastructure Systems Lab, TU Delft, CISPA, and iTrust
MIT License
48 stars 25 forks source link

Error after Installation #54

Closed jhin-coder closed 1 day ago

jhin-coder commented 4 days ago

Hello Dhalsim Team,

I have trouble running DHALSIM after installing.

I use the VMware WorkStation Pro and created a VM with the .iso of Ubuntu 20.04.6

And from the clean set up of the VM i did the following:

Installed git Cloned DHALSIM folder from the github URL Runned sudo ./install.sh Runned sudo dhalsim anytown_config.yaml

and got the following error :

evg@ubuntu:~/Desktop/DHALSIM/examples/anytown_topology$ sudo dhalsim anytown_config.yaml [sudo] password for evg: Traceback (most recent call last): File "/usr/local/bin/dhalsim", line 33, in sys.exit(load_entry_point('dhalsim', 'console_scripts', 'dhalsim')()) File "/usr/local/bin/dhalsim", line 25, in importlib_load_entry_point return next(matches).load() File "/usr/lib/python3.8/importlib/metadata.py", line 77, in load module = import_module(match.group('module')) File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import File "", line 991, in _find_and_load File "", line 975, in _find_and_load_unlocked File "", line 671, in _load_unlocked File "", line 848, in exec_module File "", line 219, in _call_with_frames_removed File "/home/evg/Desktop/DHALSIM/dhalsim/command_line.py", line 12, in from dhalsim.parser.config_parser import ConfigParser File "/home/evg/Desktop/DHALSIM/dhalsim/parser/config_parser.py", line 9, in from yamlinclude import YamlIncludeConstructor ModuleNotFoundError: No module named 'yamlinclude' evg@ubuntu:~/Desktop/DHALSIM/examples/anytown_topology$

afmurillo commented 3 days ago

Hello,

Thank you very much for using DHALSIM and taking the time to raise this issue. I would also like to apologise for this major issue that was rendering the installation unusable.

It should be fixed now in: https://github.com/Critical-Infrastructure-Systems-Lab/DHALSIM/commit/f5dddfefb6cad7fe78d7b7ab5ce42787f4e116cd, but please let me know if there are any other issues.

Thank you again!

jhin-coder commented 3 days ago

Hello,

Thank you for you immediate response, 3 weeks before the update the tool was working and only giving me warnings about some stuff which for now are not important.

As per the last update, creating again a new instance in VM and doing exactly the same steps we get the new following error

evg@ubuntu:~/Desktop/DHALSIM/examples/anytown_topology$ sudo dhalsim anytown_config.yaml [sudo] password for evg: Traceback (most recent call last): File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 584, in _build_master ws.require(requires) File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 901, in require needed = self.resolve(parse_requirements(requirements)) File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 792, in resolve raise VersionConflict(dist, req).with_context(dependent_req) pkg_resources.ContextualVersionConflict: (typing-extensions 4.12.2 (/usr/local/lib/python3.8/dist-packages), Requirement.parse('typing-extensions<4.6.0,>=3.6.6'), {'tensorflow'})

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/bin/dhalsim", line 33, in sys.exit(load_entry_point('dhalsim', 'console_scripts', 'dhalsim')()) File "/usr/local/bin/dhalsim", line 25, in importlib_load_entry_point return next(matches).load() File "/usr/lib/python3.8/importlib/metadata.py", line 77, in load module = import_module(match.group('module')) File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import File "", line 991, in _find_and_load File "", line 975, in _find_and_load_unlocked File "", line 671, in _load_unlocked File "", line 848, in exec_module File "", line 219, in _call_with_frames_removed File "/home/evg/Desktop/DHALSIM/dhalsim/command_line.py", line 12, in from dhalsim.parser.config_parser import ConfigParser File "/home/evg/Desktop/DHALSIM/dhalsim/parser/config_parser.py", line 12, in from dhalsim.parser.input_parser import InputParser File "/home/evg/Desktop/DHALSIM/dhalsim/parser/input_parser.py", line 4, in import wntr File "/usr/local/lib/python3.8/dist-packages/wntr/init.py", line 1, in from wntr import epanet File "/usr/local/lib/python3.8/dist-packages/wntr/epanet/init.py", line 6, in from . import toolkit, io, util, exceptions File "/usr/local/lib/python3.8/dist-packages/wntr/epanet/toolkit.py", line 13, in from pkg_resources import resource_filename File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 3254, in def _initialize_master_working_set(): File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 3237, in _call_aside f(*args, **kwargs) File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 3266, in _initialize_master_working_set working_set = WorkingSet._build_master() File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 586, in _build_master return cls._build_from_requirements(requires) File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 599, in _build_from_requirements dists = ws.resolve(reqs, Environment()) File "/usr/lib/python3/dist-packages/pkg_resources/init.py", line 787, in resolve raise DistributionNotFound(req, requirers) pkg_resources.DistributionNotFound: The 'typing-extensions<4.6.0,>=3.6.6' distribution was not found and is required by tensorflow

also i get the following error while Installing

ERROR: tensorflow 2.13.1 has requirement typing-extensions<4.6.0,>=3.6.6, but you'll have typing-extensions 4.12.2 which is incompatible.

At last i set up again a new VM and first i installed the specified version of tesnorflow manually before installing DHALSIM pip install tensorflow==2.13.1

Installed DHALSIM

Runned the Anytown example and it works like it used to