diff --git a/epanet/epanet.py b/epanet/epanet.py index 35a702f..c1ec5a5 100644 --- a/epanet/epanet.py +++ b/epanet/epanet.py @@ -19,7 +19,7 @@ class Output: def __init__(self, path: str) -> None: self._path = path - self._lib = ctypes.CDLL(os.path.join(os.getcwd(), 'epanet-output.dll')) + self._lib = ctypes.CDLL(os.path.join(os.getcwd(), 'epanet', 'epanet-output.dll')) self._handle = ctypes.c_void_p() self._check(self._lib.ENR_init(ctypes.byref(self._handle))) @@ -166,7 +166,7 @@ def run_project(name: str) -> str: if not project.have_project(name): raise Exception(f'Not found project [{name}]') - dir = os.path.dirname(os.getcwd()) + dir = os.path.abspath(os.getcwd()) db_inp = os.path.join(os.path.join(dir, 'db_inp'), name + '.db.inp') parser.dump_inp(name, db_inp) @@ -187,7 +187,7 @@ def run_project(name: str) -> str: def run_inp(name: str) -> str: - dir = os.path.dirname(os.getcwd()) + dir = os.path.abspath(os.getcwd()) exe = os.path.join(os.path.join(dir, 'epanet'), 'runepanet.exe') inp = os.path.join(os.path.join(dir, 'inp'), name + '.inp')