From 3a33458dd16375c87ca86a702be84340a4ccb39e Mon Sep 17 00:00:00 2001
From: Lacroix Martin <martin.lacroix@uliege.be>
Date: Thu, 26 Oct 2023 11:32:27 +0000
Subject: [PATCH] Update CUPyDO Wrapper

---
 dart/api/cupydo.py | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/dart/api/cupydo.py b/dart/api/cupydo.py
index 9a7bc6a..382d844 100644
--- a/dart/api/cupydo.py
+++ b/dart/api/cupydo.py
@@ -24,9 +24,9 @@ import sys
 class Dart(FluidSolver):
     """DART interface for CUPyDO
     """
-    def __init__(self, _module, _nthreads):
+    def __init__(self, p, _nthreads):
         # load the python module and initialize the solver
-        module = __import__(_module)
+        module = __import__(p['cfdFile'])
         params = module.getParams()
         params['Threads'] = _nthreads
         from dart.api.core import initDart
@@ -46,7 +46,7 @@ class Dart(FluidSolver):
             self.saveFreq = sys.maxsize
 
         # generic init
-        FluidSolver.__init__(self)
+        FluidSolver.__init__(self, p)
 
     def run(self, t1, t2):
         """Run the solver for one steady (time) iteration.
@@ -87,7 +87,7 @@ class Dart(FluidSolver):
         no = self.boundary.nodes[iVertex].no
         return no
 
-    def applyNodalDisplacements(self, dx, dy, dz, dx_nM1, dy_nM1, dz_nM1, haloNodesDisplacements, time):
+    def applyNodalDisplacements(self, dx, dy, dz, dt, haloNodesDisplacements):
         """Apply displacements coming from solid solver to f/s interface after saving
         """
         self.morpher.savePos()
@@ -139,3 +139,4 @@ class Dart(FluidSolver):
         del self.morpher
         del self.writer
         del self.msh
+        
\ No newline at end of file
-- 
GitLab