Forum Replies Created
-
AuthorPosts
-
GuillaumeKeymaster
Hi Charlie,
Where did you get SoftRobots.dll from?
GuillaumeKeymasterWhat is the output if you run
~/SOFA/v21.12.00/bin/runSofa -l SofaPython3 ~/catkin_ws/src/sofaros/src/test_sofaros.py
GuillaumeKeymasterHi,
Could you provide the command you executed to get this output?
Thanks.
GuillaumeKeymasterHi Yuan,
Your environment looks good: PATH and PYTHONPATH are OK (PYTHONPACKAGE is useless, I think Hugo wanted to say PYTHONPATH).
The next step for you is to investigate which dependency of
Sofa.Gui
is not found, leading to the very unclear Windows error “DLL load failed” (thank you Windows).To do that, I suggest you download the latest release of lucasg/Dependencies.
Unzip it on your computer and run the executable “DependenciesGui.exe”.In DependenciesGui, open the file
C:\SOFA\SOFA_v21.06.01_Win64\plugins\SofaPython3\lib\python3\site-packages\Sofa\Gui.cp37-win_amd64.pyd
.You should get a better idea of what is not found in the dependencies (upper-left part of DependenciesGui).
Hope that helps!
Guillaume.GuillaumeKeymasterHi, sorry for the very late answer.
However, adding things manually is a bit of a hacky solution, I guess there is something wrong that prevent my dlls from being accessible/correctly loaded when running the .exe file. Can you also reproduce this error?
I agree it looks like a hacky solution but actually it’s the way Windows works. On Linux and MacOS, each library/executable has a RPATH: a list of folder hints to search for dependencies. There is no RPATH on Windows, thus we have to copy DLLs…
In SOFA, DLLs copy (among other things) after the install step on Windows is provided by a script under tools/postinstall-fixup.
To auto-run this script you can set-DSOFA_BUILD_RELEASE_PACKAGE=ON
.Hope that helps,
Guillaume.22 April 2021 at 16:20 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19274GuillaumeKeymasterHi Serkan,
Sorry for the delay.
I just checked and, as I suspected, the stlib3 packages are not stable yet.Compared to stlib, a lot of assets are missing and thus a scene created with stlib cannot be used with stlib3 by simply importing stlib3 instead of stlib.
Unfortunately, it looks like that’s what has been done for step4.pyscn: the python2 scene wasSoftRobots\docs\tutorials\FirstSteps\details\step4.pyscn
and it was converted toSoftRobots\docs\tutorials\FirstSteps\details\sofapython3\step4.py3scn
simply by importing stlib3 instead of stlib.I simpler words: consider that scenes using stlib3 might not work.
I will definitely push for a cleaning of all those scenes for the next SOFA release.Thus, I advise that – for now – you stay on the old (but stable) stack:
Python2.7 + SofaPython + STLIB + SoftRobots
With this stack, I successfully loaded the Python2 version of the scene you are working with:SoftRobots\docs\tutorials\FirstSteps\details\step4.pyscn
Still, if you want to stick to Python3, it would be awesome to report on this topic or on a dedicated issue the scenes that are broken, the errors you encountered, and how you fixed them (if you did).
Hope that helps,
Guillaume.20 April 2021 at 16:50 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19235GuillaumeKeymasterOk, there is an issue with SOFA “.exe” installer, thanks for spotting that!
Could you replace your SOFA with the “.zip” version and try again?
20 April 2021 at 16:37 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19233GuillaumeKeymasterWhere did you put
import stlib3
?
I’m afraid you won’t be able to simply convert a scene using stlib/splib (python2) by replacing all the imports to stlib3/splib3 (python3) because, as far as I know, all stlib/splib features have not been ported to stlib3/splib3.In your output, the line
[INFO] [SofaPython3] No python3 dir found in C:/Users/seergun/SOFA/v20.12.02/plugins/STLIB
is not normal.
SofaPython3 should findC:/Users/seergun/SOFA/v20.12.02/plugins/STLIB/lib/python3/site-packages
.
Do you have this directory?20 April 2021 at 15:56 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19231GuillaumeKeymasterIndeed stlib3 contains a python3 version of STLIB.
It is located inSTLIB/lib/python3/site-packages
.Actually you have to choose :
– If you runrunSofa -lSofaPython -lSTLIB
(with python2 correctly set up in your environment) you will be able to load python2 scenes which containimport stlib
– If you runrunSofa -lSofaPython3 -lSTLIB
(with python3 correctly set up in your environment) you will be able to load python3 scenes which containimport stlib3
Thus, if you do
runSofa -lSofaPython3 -lSTLIB
you CANNOT load a scene which containsimport stlib
because the “stlib” package is a python2 package.If the “stlib” package is critical for you and cannot be replaced with “stlib3”, you will have to switch to SofaPython2 (and setup python2 in your environment).
Hope that helps,
Guillaume.20 April 2021 at 14:50 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19225GuillaumeKeymasterI think I understand the issue.
Please try running
runSofa -lSofaPython3
to force SofaPython3 to be loaded before any other plugin.
OR, you can also move upper the SofaPython3 line you added inplugin_list.conf
(I suppose you did that).The thing is SofaPython3 must be loaded before STLIB in order to have STLIB’s site-packages added to
sys.path
`.Hope that helps,
Guillaume.20 April 2021 at 10:22 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19218GuillaumeKeymasterCould you please paste the entire log of your runSofa execution?
From your runSofa command line until the end of the crash log.Thanks,
Guillaume.16 April 2021 at 11:28 in reply to: [SOLVED] SofaPython3 with v20.12.02 binary install on Win10 #19202GuillaumeKeymasterHi,
The line
[INFO] [SofaPython3] No python3 dir found in C:/Users/seergun/SOFA/v20.12.02
is an old issue that has not been cleaned yet, but it is not fatal.
Thus it is not the reason of your crash.What happens if you open Windows Console (cmd.exe) and run
python -V
?Hope that helps,
Guillaume.GuillaumeKeymasterHi,
You don’t have to download and build GLEW by yourself.
As explained in build SOFA on Linux documentation, you simply need to runsudo apt install libglew-dev
and CMake will then find GLEW in your system.Hope that helps,
Guillaume.GuillaumeKeymasterHi Olumide,
It looks like you are basing your project on a SOFA-build instead of a SOFA-install.
You shouldmake install
your SOFA and change the CMAKE_PREFIX_PATH to something likecmake -DCMAKE_PREFIX_PATH=/home/Olumide/sofa/src/Release/install .
Hope that helps,
Guillaume.GuillaumeKeymasterHi,
It seems your build directory contains an old version of SofaSimulationCommon.
Try removing<your-SOFA-build-directory>/include/SofaSimulationCommon
and compile again.Cheers,
Guillaume.GuillaumeKeymasterHi,
To debug this kind of issue you can load the problematic DLLs (here SoftRobots.dll) in a dependency checker like Dependency Walker on Windows.
Besides, I recommend you to switch to SOFA v20.12.01 if you can. All the plugins you need are embedded in it.
Cheers,
Guillaume.22 March 2021 at 18:26 in reply to: [SOLVED] Error in first launch of sofa after installation #18940GuillaumeKeymasterHi,
Indeed there seems to be an issue in the binaries.
Could you try to move the directoriesbin/resources
andbin/translations
at the top of SOFA install directory (one level higher basically) and execute again runSofa?Guillaume.
12 March 2021 at 17:00 in reply to: [SOLVED] Error building SOFA : ConstraintResolution.h not found #18848GuillaumeKeymasterThe file is new, it was added in SOFA master by #1847.
You have 2 solutions:
– Keep your SOFA on v20.12 branch and switch SoftRobots to its v20.12 branch.
OR
– Switch your SOFA to master branch and keep SoftRobots on its master branch.Hope that helps,
Guillaume.12 March 2021 at 11:54 in reply to: [SOLVED] Error building SOFA : ConstraintResolution.h not found #18846GuillaumeKeymasterHi Mathieu,
Could you make sure that
/home/srl/sofa/src/SofaKernel/modules/SofaCore/src/sofa/core/behavior/ConstraintResolution.h
exists?If yes, please paste here your CMakeCache.txt (located in the build directory).
Thanks,
Guillaume.GuillaumeKeymasterHi eaparra,
I would suggest you take a look at this pull-request, which is an unfinished work about adding communication protocols to SOFA within a plugin.
Even though this work is not merged in SOFA (yet), I think it could be a good starting point for what you want to do.Cheers,
Guillaume.12 March 2021 at 10:42 in reply to: Error while building Sofa for SoftRobots plugin installation #18843GuillaumeKeymasterHi,
Could you copy/paste IN THIS PAD a more complete output containing the error please?
Paste the entire output if you don’t know where is the error.Thanks!
Guillaume.GuillaumeKeymasterHi Peluntra,
What is your CMake version?
You could try replacing with CMake-GUI all occurrences of
/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/OpenGL.framework
by/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework
EDIT: you can also try replacing by
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework
Hope that helps,
Guillaume.GuillaumeKeymasterHi Pho,
SofaSimulationGraph is now a plugin and is installed in
/plugins/SofaSimulationGraph In order to be able to find_package plugins, you must add
/plugins to CMAKE_PREFIX_PATH. Thus, in your case you should do:
cmake -DCMAKE_PREFIX_PATH="$SOFA_BLD/install/lib/cmake;$SOFA_BLD/install/plugins" $SP3_SRC
GuillaumeKeymasterHi @ajay,
Are you building out-of-SOFA or in-SOFA (using SOFA_EXTERNAL_DIRECTORIES)?
If you are building out-of-SOFA, you must
1. build and install STLIB
2. tell SoftRobots where to find STLIB by adding your STLIB install path into SoftRobots’ CMAKE_PREFIX_PATHHope this helps,
Guillaume.GuillaumeKeymasterHi guys,
Since the issue linked by Hugo has been fixed, I mark this topic as Solved. Do not hesitate to answer if it’s not.
-
AuthorPosts