FlowEngine is not defined in yade-daily - On Ubuntu 13.10
Hi all,
I am new to ubuntu and yade. I need to do some simulations on DEM-PFV coupled analysis and I need to use FlowEngine. So, I tried to compile YADE from trunk. Here is the procedure I used:
Note :I used " /home/ehsan/
1) "git clone https:/
2) installed the prerequisites according to the "installation" web- page of yade
3) cd /home/ehsan/
4) cmake -DINSTALL_
5) cmake -DOPTION1=VALUE1 -DOPTION2=VALUE2
6) make
7) make install
You can find the log here
However, when I try to run a simple flowengine-based example (which I am sure already worked with my previous os (linux mint 15)), does not work!
I get "NameError: name 'FlowEngine' is not defined"
Can anyone help me?
Thank you in advance.
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Yade Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Bruno Chareyre
- Solved:
- Last query:
- Last reply:
Revision history for this message
|
#1 |
Here you can find the log:
https:/
Revision history for this message
|
#2 |
Thanks for reporting Ehsan.
We need more info on step 2. Could you please do it again and report exactly the commands you type and the output they give (you can paste it in plain text here)?
Step 5 is useless and, in fact, meaningless. You can simply suppress it.
You are supposed to replace OPTION1 with something, which is what you do in step 4 (where OPTION1 is INSTALL_PREFIX, and you don't have any OPTION2).
I in fact recommend this for (4):
cmake -DINSTALL_
Revision history for this message
|
#3 |
Hi Ehsen
You have to specify what you need in your options in cmake (and not write simply -DOPTION1=VALUE1 -DOPTION2=VALUE2). Step 4 and 5 can be in the same line and with the same command "cmake"
To work with flowEngine, you need probably to add in your options in the cmake command: -DENABLE_LINSOLV = ON
So you will have something like this:
cmake -DINSTALL_
Bests
Donia
Revision history for this message
|
#4 |
@Donia
-DENABLE_LINSOLV is no longer needed. It is enabled by default (or should be).
Revision history for this message
|
#5 |
Ehsan,
I did test to compile yade on the same system as yours and I did not see the problem. There is maybe a problem in step 2.
Could you type the following commands and paste the output here (output of the first command excepted):
sudo apt-get install aptitude
aptitude search '~i' | grep metis
aptitude search '~i' | grep openblas
aptitude search '~i' | grep suitesparse
aptitude search '~i' | grep cgal
Revision history for this message
|
#6 |
Bruno,
I've installed libsuitesparse-
Actually because I installed the prerequisites long time ago, it is quite hard to say what I've already installed on my Ubuntu 13.10.
However, I installed aptitude and you can find the out put of the commands you asked:
-aptitude search '~i' | grep metis:
i libmetis-dev - Serial Graph Partitioning and Fill-reducin
i A libmetis5 - Serial Graph Partitioning and Fill-reducin
i libparmetis-dev - Parallel Graph Partitioning and Sparse Mat
i A libparmetis3.1 - Parallel Graph Partitioning and Sparse Mat
i A libsuitesparse-
i libsuitesparse-
-aptitude search '~i' | grep openblas:
i A libopenblas-base - Optimized BLAS (linear algebra) library ba
i libopenblas-dev - Optimized BLAS (linear algebra) library ba
-aptitude search '~i' | grep suitesparse:
i A libsuitesparse-
i libsuitesparse-
-aptitude search '~i' | grep cgal
i libcgal-dev - C++ library for computational geometry (de
i A libcgal-qt4-10 - C++ library for computational geometry (su
i libcgal-qt4-dev - C++ library for computational geometry (de
i A libcgal10 - C++ library for computational geometry
Any suggestions?
Revision history for this message
|
#7 |
Hi Ehsan,
I just discovered a bug on 14.04, which may also affect you on 13.10 [1].
From what you posted here, I don't see anything missing in the
libraries. So this bug has a high chance to be your problem.
If you are in this case of having a stable yade package installed on the
same machine you are compiling on, you may have to uninstall the stable
yade.
The reason is that the stable version it is hiding your compiled version
no matter what you do. And since the stable version has no FlowEngine
you don't have it either.
/
sudo apt-get remove//yade
/Then try your compiled version again.
If it crashes, it is a good sign: you are in the case of the previous
bug and should not be too difficult to fix.
You may have to re-install manually a few libraries that could be
removed together with yade:
sudo apt-get install python-gts python-minieigen
If it still doesn't work. Try recompiling the sources.
Let us know.
Bruno
Revision history for this message
|
#8 |
Sorry, it is:
sudo apt-get remove yade
I don't know how slash came into my message.
Revision history for this message
|
#9 |
Thanks Bruno Chareyre, that solved my question.
Revision history for this message
|
#10 |
Great!
Now I'm afraid the fluid code may crash randomly, because of a bad bug in libstdc++ shiped by g++-4.8 [1]. If you don't get any crash, then don't touch anything.
Else, there is one line to remove from yade code as a workaround [2].
To update your source code go in trunk directory and type "git pull". Then re-compile (the "make install" part, no need to type cmake again, it will recompile only the modified files, which should be a lot faster than first compilation).
Bruno
For those interested:
[1] http://
[2] https:/
Revision history for this message
|
#11 |
Hi all,
I got a similar error: "NameError: name 'TwoPhaseFlowEn
After a normal update in Ubuntu, my operation system was crash. I have reinstalled Ubuntu (version 14.04.5 LTS (Trusty Tahr) ). When I compiled binary Yade, I got the above error.
The following is my installation procedure (for yade-2016.06a)
sudo add-apt-repository ppa:yade-
sudo apt-get update
sudo apt-get install cmake git freeglut3-dev libloki-dev \
libboost-all-dev fakeroot dpkg-dev build-essential g++ \
python-dev ipython python-matplotlib libsqlite3-dev python-numpy python-tk gnuplot \
libgts-dev python-pygraphviz libvtk6-dev python-numpy libeigen3-dev \
python-xlib python-pyqt5 pyqt5-dev-tools python-
libqglviewer-dev python-imaging libjs-jquery python-sphinx python-git python-bibtex \
libxmu-dev libxi-dev libcgal-dev help2man libbz2-dev zlib1g-dev python-minieigen
(after this command, i got:
Note, selecting 'libpython2.
E: Unable to locate package python-pyqt5
E: Unable to locate package python-
E: Couldn't find any package by regex 'python-
sudo apt-get install python-gts
sudo apt-get install libopenblas-dev libsuitesparse-
sudo add-apt-repository ppa:yade-
sudo apt-get update
My Compilation:
My folder structure:
myYade/
trunk/ ## downloaded from https:/
build/ ## downloaded from https:/
install/ ## initially is a blank folder
cd /home/son/
In the build-directory, I have entered these following command in terminal window:
son@
cmake -DCMAKE_
-DUSE_QT5=OFF is because: https:/
After this, I got:
Yade will be installed to /home/son/
-- Suffix is set to -2016.06a
-- LIBRARY_OUTPUT_PATH is set to lib/x86_
-- runtimePREFIX is set to /home/son/
-- Found gts: /usr/lib/
-- Use system gts version
-- Found minieigen: /usr/lib/
-- Found Tkinter: /usr/lib/
-- =======
-- Yade configured with following features: Odeint VTK OpenMP GTS GUI CGAL PFVFLOW LINSOLV GL2PS LBMFLOW
-- Disabled features: SPH LIQMIGRATION MASK_ARBITRARY PROFILING PotentialParticles
-- Optimized build
-- =======
-- Configuring done
-- Generating done
-- Build files have been written to: /home/son/
son@son-
[ 0%] Generating qt4/moc_
[ 1%] Scanning dependencies of target WeightedAverage2d
Scanning dependencies of target _packObb
Generating qt4/moc_
[ 2%] [ 2%] Building CXX object py/CMakeFiles/
Building CXX object py/CMakeFiles/
Scanning dependencies of target _polyhedra_utils
Scanning dependencies of target _GLViewer
[ 3%] Building CXX object py/CMakeFiles/
[ 4%] Building CXX object gui/CMakeFiles/
Linking CXX shared library lib/x86_
[ 4%] Built target _packObb
[ 5%] Building CXX object gui/CMakeFiles/
In file included from /usr/lib/
/usr/lib/
#warning "Using deprecated NumPy API, disable it by " \
^
Linking CXX shared library lib/x86_
[ 5%] Built target WeightedAverage2d
[ 5%] Building CXX object gui/CMakeFiles/
[ 6%] Building CXX object gui/CMakeFiles/
[ 6%] Building CXX object gui/CMakeFiles/
[ 7%] Building CXX object gui/CMakeFiles/
Linking CXX shared library lib/x86_
[ 7%] Built target _polyhedra_utils
[ 8%] Building CXX object gui/CMakeFiles/
Linking CXX shared library lib/x86_
[ 8%] Built target _GLViewer
Scanning dependencies of target yade
[ 10%] [ 10%] [ 10%] [ 11%] Building CXX object CMakeFiles/
Building CXX object CMakeFiles/
Building CXX object CMakeFiles/
Building CXX object CMakeFiles/
[ 11%] Building CXX object CMakeFiles/
[ 12%] Building CXX object CMakeFiles/
[ 13%] Building CXX object CMakeFiles/
[ 13%] Building CXX object CMakeFiles/
[ 14%] Building CXX object CMakeFiles/
[ 14%] Building CXX object CMakeFiles/
[ 15%] Building CXX object CMakeFiles/
[ 16%] Building CXX object CMakeFiles/
[ 16%] Building CXX object CMakeFiles/
[ 17%] Building CXX object CMakeFiles/
[ 17%] Building CXX object CMakeFiles/
[ 18%] Building CXX object CMakeFiles/
[ 19%] Building CXX object CMakeFiles/
[ 19%] Building CXX object CMakeFiles/
[ 20%] Building CXX object CMakeFiles/
[ 20%] Building CXX object CMakeFiles/
[ 21%] Building CXX object CMakeFiles/
[ 22%] Building CXX object CMakeFiles/
[ 22%] Building CXX object CMakeFiles/
[ 23%] Building CXX object CMakeFiles/
[ 23%] Building CXX object CMakeFiles/
[ 24%] Building CXX object CMakeFiles/
[ 25%] Building CXX object CMakeFiles/
[ 25%] Building CXX object CMakeFiles/
[ 26%] Building CXX object CMakeFiles/
[ 26%] Building CXX object CMakeFiles/
[ 27%] Building CXX object CMakeFiles/
[ 28%] Building CXX object CMakeFiles/
[ 28%] Building CXX object CMakeFiles/
[ 29%] Building CXX object CMakeFiles/
[ 29%] Building CXX object CMakeFiles/
[ 30%] Building CXX object CMakeFiles/
[ 31%] Building CXX object CMakeFiles/
[ 31%] Building CXX object CMakeFiles/
[ 32%] Building CXX object CMakeFiles/
[ 32%] Building CXX object CMakeFiles/
[ 33%] Building CXX object CMakeFiles/
[ 34%] Building CXX object CMakeFiles/
[ 34%] Building CXX object CMakeFiles/
[ 35%] Building CXX object CMakeFiles/
[ 35%] Building CXX object CMakeFiles/
[ 36%] Building CXX object CMakeFiles/
[ 37%] Building CXX object CMakeFiles/
[ 37%] Building CXX object CMakeFiles/
[ 38%] Building CXX object CMakeFiles/
[ 38%] Building CXX object CMakeFiles/
[ 39%] Building CXX object CMakeFiles/
[ 40%] Building CXX object CMakeFiles/
[ 40%] Building CXX object CMakeFiles/
[ 41%] Building CXX object CMakeFiles/
[ 41%] Building CXX object CMakeFiles/
[ 42%] Building CXX object CMakeFiles/
[ 43%] Building CXX object CMakeFiles/
[ 43%] Building CXX object CMakeFiles/
[ 44%] Building CXX object CMakeFiles/
[ 44%] Building CXX object CMakeFiles/
[ 45%] Building CXX object CMakeFiles/
[ 46%] Building CXX object CMakeFiles/
[ 46%] Building CXX object CMakeFiles/
[ 47%] Building CXX object CMakeFiles/
[ 48%] Building CXX object CMakeFiles/
[ 48%] Building CXX object CMakeFiles/
[ 49%] Building CXX object CMakeFiles/
[ 49%] Building CXX object CMakeFiles/
In file included from /home/son/
/home/son/
/home/son/
}
^
In file included from /home/son/
/home/son/
/home/son/
}
^
[ 50%] Building CXX object CMakeFiles/
In file included from /usr/include/
/usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
In file included from /usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
In file included from /usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
In file included from /usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
In file included from /usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
In file included from /usr/include/
/usr/include/
^
/home/son/
Vector3r min,max;
^
[ 51%] Building CXX object CMakeFiles/
[ 51%] Building CXX object CMakeFiles/
In file included from /usr/lib/
/usr/lib/
#warning "Using deprecated NumPy API, disable it by " \
^
[ 52%] Building CXX object CMakeFiles/
[ 52%] Building CXX object CMakeFiles/
[ 53%] Building CXX object CMakeFiles/
In file included from /usr/lib/
/usr/lib/
_import_
^
[ 54%] Building CXX object CMakeFiles/
[ 54%] Building CXX object CMakeFiles/
[ 55%] Building CXX object CMakeFiles/
[ 55%] Building CXX object CMakeFiles/
[ 56%] Building CXX object CMakeFiles/
[ 57%] Building CXX object CMakeFiles/
[ 57%] Building CXX object CMakeFiles/
[ 58%] Building CXX object CMakeFiles/
[ 58%] Building CXX object CMakeFiles/
[ 59%] Building CXX object CMakeFiles/
[ 60%] Building CXX object CMakeFiles/
[ 60%] Building CXX object CMakeFiles/
[ 61%] Building CXX object CMakeFiles/
[ 61%] Building CXX object CMakeFiles/
[ 62%] Building CXX object CMakeFiles/
[ 63%] Building CXX object CMakeFiles/
[ 63%] Building CXX object CMakeFiles/
[ 64%] Building CXX object CMakeFiles/
[ 64%] Building CXX object CMakeFiles/
[ 65%] Building CXX object CMakeFiles/
[ 66%] Building CXX object CMakeFiles/
[ 66%] Building CXX object CMakeFiles/
[ 67%] Building CXX object CMakeFiles/
[ 67%] Building CXX object CMakeFiles/
In file included from /usr/include/
/usr/include/
#warning \
^
[ 68%] Building CXX object CMakeFiles/
[ 69%] Building CXX object CMakeFiles/
[ 69%] Building CXX object CMakeFiles/
[ 70%] Building CXX object CMakeFiles/
[ 70%] Building CXX object CMakeFiles/
[ 71%] Building CXX object CMakeFiles/
[ 72%] Building CXX object CMakeFiles/
[ 72%] Building CXX object CMakeFiles/
[ 73%] Building CXX object CMakeFiles/
[ 73%] Building CXX object CMakeFiles/
In file included from /home/son/
/home/son/
/home/son/
fscanf(fp, "%*s %*s %f %f %f\n", &n[0], &n[1], &n[2]);
^
/home/son/
fscanf(fp, "%*s %*s");
^
/home/son/
fscanf(fp, "%*s %f %f %f\n", &v[0][0], &v[0][1], &v[0][2]);
^
/home/son/
fscanf(fp, "%*s %f %f %f\n", &v[1][0], &v[1][1], &v[1][2]);
^
/home/son/
fscanf(fp, "%*s %f %f %f\n", &v[2][0], &v[2][1], &v[2][2]);
^
/home/son/
fscanf(fp, "%*s"); // end loop
^
/home/son/
fscanf(fp, "%*s"); // end facet
^
[ 74%] Building CXX object CMakeFiles/
[ 75%] Building CXX object CMakeFiles/
[ 75%] Building CXX object CMakeFiles/
[ 76%] Building CXX object CMakeFiles/
[ 76%] Building CXX object CMakeFiles/
[ 77%] Building CXX object CMakeFiles/
[ 78%] Building CXX object CMakeFiles/
[ 78%] Building CXX object CMakeFiles/
[ 79%] Building CXX object CMakeFiles/
[ 79%] Building CXX object CMakeFiles/
In file included from /usr/lib/
/usr/lib/
#warning "Using deprecated NumPy API, disable it by " \
^
[ 80%] Building CXX object CMakeFiles/
[ 81%] Building CXX object CMakeFiles/
[ 81%] Building CXX object CMakeFiles/
[ 82%] Building CXX object CMakeFiles/
[ 82%] Building CXX object CMakeFiles/
In file included from /usr/lib/
/usr/lib/
_import_
^
[ 83%] Building CXX object CMakeFiles/
[ 84%] Building CXX object CMakeFiles/
[ 84%] Building CXX object CMakeFiles/
[ 85%] Building CXX object CMakeFiles/
[ 85%] Building CXX object CMakeFiles/
[ 86%] Building CXX object CMakeFiles/
[ 87%] Building CXX object CMakeFiles/
[ 87%] Building CXX object CMakeFiles/
[ 88%] Building CXX object CMakeFiles/
[ 88%] Building CXX object CMakeFiles/
[ 89%] Building CXX object CMakeFiles/
[ 90%] Building CXX object CMakeFiles/
[ 90%] Building CXX object CMakeFiles/
[ 91%] Building CXX object CMakeFiles/
[ 91%] Building CXX object CMakeFiles/
[ 92%] Building CXX object CMakeFiles/
[ 93%] Building CXX object CMakeFiles/
[ 93%] Building CXX object CMakeFiles/
[ 94%] Building CXX object CMakeFiles/
[ 94%] Building CXX object CMakeFiles/
[ 95%] Building CXX object CMakeFiles/
[ 96%] Building CXX object CMakeFiles/
[ 96%] Building CXX object CMakeFiles/
[ 97%] Building CXX object CMakeFiles/
[ 98%] Building CXX object CMakeFiles/
Linking CXX shared library lib/x86_
[ 98%] Built target yade
Scanning dependencies of target boot
Scanning dependencies of target _packPredicates
Scanning dependencies of target _customConverters
Scanning dependencies of target _packSpheres
[ 99%] [100%] [100%] Building CXX object py/CMakeFiles/
Building CXX object py/CMakeFiles/
Building CXX object CMakeFiles/
[100%] Building CXX object py/CMakeFiles/
Linking CXX shared library lib/x86_
Linking CXX shared library lib/x86_
[100%] Built target boot
Scanning dependencies of target _utils
[100%] Building CXX object py/CMakeFiles/
[100%] Built target _packPredicates
Scanning dependencies of target wrapper
[100%] Building CXX object py/CMakeFiles/
Linking CXX shared library lib/x86_
[100%] Built target _packSpheres
In file included from /usr/lib/
/usr/lib/
#warning "Using deprecated NumPy API, disable it by " \
^
Linking CXX shared library lib/x86_
[100%] Built target _customConverters
Linking CXX shared library lib/x86_
[100%] Built target wrapper
Linking CXX shared library lib/x86_
[100%] Built target _utils
son@son-
[ 6%] Built target _GLViewer
[ 96%] Built target yade
[ 97%] Built target boot
[ 97%] Built target WeightedAverage2d
[ 97%] Built target _customConverters
[ 98%] Built target _packObb
[ 98%] Built target _packPredicates
[ 99%] Built target _packSpheres
[100%] Built target _polyhedra_utils
[100%] Built target _utils
[100%] Built target wrapper
Install the project...
-- Install configuration: ""
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
-- Installing: /home/son/
-- Set runtime path of "/home/
cd
cd Desktop/
son@son-
son@son-
son@son-
Welcome to Yade 2016.06a
TCP python prompt on localhost:9000, auth cookie `aseyku'
XMLRPC info provider on http://
[[ ^L clears screen, ^U kills line. F12 controller, F11 3d view (use h-key for showing help), F10 both, F9 generator, F8 plot. ]]
And I got: NameError: name 'TwoPhaseFlowEn
Before these re-installations, I had no problem with these Flow Engines.
Any idea about how to solve this would be greatly appreciated!
Thanks,
Son
Revision history for this message
|
#12 |
Hi,
Thank you very much for browsing the archives first, but it seems your problem deserved a new question, here. FlowEngine and TwoPhaseFlowEngine are indeed two different pieces of code (the former dealing with the flow of one pore fluid, the latter with the flow of two pore fluids). Also, your Ubuntu version does not match the initial question.
Anyway, I'm assuming your problem is caused by compilation of some part of TwoPhaseFlowEngine related code, while most part is still skipped during compilation (I think TwoPhaseFlowEngine package has not been yet "officially" released by the corresponding developers -- not me).
You may try uncomment line 16 of trunk/pkg/
If this does not work, you may consider open a new question and wait for other answers..
[*] https:/
Revision history for this message
|
#13 |
Hi Jérôme,
Thank for your reply. Following your suggestion, I have uncommented (deleted the //) line 16 of trunk/pkg/
And now, it works fine :)
Thanks Jérôme Duriez, my question has been solved.
Regards,
Son.
Revision history for this message
|
#14 |
Hi Son,
Modifying the source code to escape a compile error is the best starting point for big troubles.
If you have compile errors please fill a bug report (this problem you have is now solved in latest trunk IIRC), and please don't append more questions to existing ones.
Bruno