RAFT icon indicating copy to clipboard operation
RAFT copied to clipboard

Question: VolturnUs example not working when setting potModMaster to 0

Open maucollu opened this issue 2 years ago • 4 comments

Dear all, I've followed all the instructions to install RAFT, and I am able to successfully run the example script in https://openraft.readthedocs.io/en/latest/starting.html using the VolturnUS-S.yaml default file. Nonetheless, the setting for potModMaster is 1, i.e. "1=turns all potMod vars to False (no HAMS)", although some of the elements (center_column and outer_column are defined as "potMod : True". When I change potModMaster to 0 (0=keeps all member potMod vars the same), I obtain the following error: `Found mean offets with with surge = 0.02 m and pitch = 0.00 deg.

--------- Natural frequencies and mode shapes ------------- Mode 1 2 3 4 5 6 Fn (Hz) 0.0087 0.0087 0.0611 0.0405 0.0405 0.0150

DOF 1 -1.0000 -0.0129 0.0000 0.0003 -0.9889 -0.0000 DOF 2 0.0000 -0.9999 0.0000 -0.9889 0.0001 0.0888 DOF 3 -0.0000 -0.0000 -1.0000 -0.0000 0.0000 -0.0000 DOF 4 0.0000 -0.0006 -0.0000 0.1487 -0.0000 0.0002 DOF 5 0.0006 0.0000 0.0000 0.0000 -0.1486 0.0000 DOF 6 -0.0000 0.0001 0.0000 0.0000 -0.0000 0.9960

Of 312 generated panels, 172 were submerged and have been used in the mesh. Of 600 generated panels, 332 were submerged and have been used in the mesh. Of 600 generated panels, 332 were submerged and have been used in the mesh. Of 600 generated panels, 332 were submerged and have been used in the mesh. Traceback (most recent call last):

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\site-packages\spyder_kernels\py3compat.py", line 356, in compat_exec exec(code, globals, locals)

File "c:\users\mauri\onedrive_maurizio_company\sandbox\raft\raft_example.py", line 27, in model.analyzeCases(display=1)

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\site-packages\raft\raft_model.py", line 236, in analyzeCases fowt.calcBEM(meshDir=meshDir)

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\site-packages\raft\raft_fowt.py", line 391, in calcBEM ph.run_hams(meshDir)

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\site-packages\pyhams\pyhams.py", line 404, in run_hams sub.run([f'{hamsPath}'])

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\subprocess.py", line 503, in run with Popen(*popenargs, **kwargs) as process:

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 109, in init super(SubprocessPopen, self).init(*args, **kwargs)

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\subprocess.py", line 971, in init self._execute_child(args, executable, preexec_fn, close_fds,

File "C:\Users\mauri\anaconda3\envs\spyder-env-WSDM\lib\subprocess.py", line 1440, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args,

FileNotFoundError: [WinError 2] The system cannot find the file specified`

maucollu avatar Dec 15 '22 15:12 maucollu

@maucollu, thanks for raising this issue. We still need to set up some proper tests for RAFT to catch things like this sooner. It sounds like something isn't working out with the call to HAMS.

@gbarter, would you have any insights on this error, or a suggestion of who would be well suited to look into it?

mattEhall avatar Dec 20 '22 22:12 mattEhall

I'm not immediately sure what the issue is. It reads like pyHAMS cannot find or open the windows executable that it currently ships with. Since it looks like pyHAMS is installed from the error message, this will indeed take some testing. I can try to take a look next week.

gbarter avatar Dec 21 '22 02:12 gbarter

@maucollu, thanks for raising this issue. We still need to set up some proper tests for RAFT to catch things like this sooner. It sounds like something isn't working out with the call to HAMS.

@mattEhall Perhaps a 'debug' toggle for the user to switch on which would provide a little more information?

e.g.

def run_hams(projectDir):
    '''call the HAMS_x64.exe program in the specified project directory'''
    # get absolute path to the local HAMS_x64.exe program
    hamsDir = osp.dirname(__file__)
    hamsExe = './bin/HAMS_x64.exe'
    hamsPath = osp.abspath(osp.join(hamsDir, hamsExe))
    if debugToggle is True:
        print(hamsDir)
        print(hamsExe)
        print(hamsPath)

to see if there is a path mix-up?

(or maybe save a .log file instead of just printing)

dav-og avatar Dec 21 '22 12:12 dav-og

Hi all,

I have migrated pyHAMS to a more current build system (meson with ninja), which seems to be the way that SciPy and other major python numerical tools are migrating. I have also added a regression test in the CI that checks a cylinder run via pyHAMS against truth values in the upstream HAMS repo. This is run on Windows and Linux and is passing.

@maucollu - Please update to the latest pyHAMS and reinstall that package. If you continue to see the same error, then we know it is an issue with your system in particular.

Cheers, Garrett

gbarter avatar Dec 27 '22 22:12 gbarter