Discussion:
[deprecated list] crash in lattice model
Jingsong Chen
2009-06-27 14:58:45 UTC
Permalink
Dear Janek Kozicki:

thank you for your suggestion, and i tried your method, but it still
crashed as before.

i also tried the simple FileGenerator examples in the code in latest
trunk. I should made some change in the code to let it through when i
compiled it (delete latticeLaw->tension_compression_different_stiffness
= true; add "false" in REGISTER_SERIALIZABLE(LatticeExampleSimple); ).
Then the compilation succeed.

For the simple example, once after I started the simulation, the four
control button in the Simulation tab of the Simulation Controller turn
grey, I can not stop or pause the simulation by myself. The simulation
will not stop, and there is no items in the OpenGL display (before i
started the simulation, i can see some node in the display).

I also found this in terminal.
"/home/daisy/build-0.12rc1/include/yade-0.12rc1/yade/core/MetaEngine2D.hpp:61
WARNING! dynamic cast of engine unit LatticeSet2LatticeBeams failed,
will use static_cast. Go figure why."

I think there may exist problems in version. some code can work in old
version (like version yade-0.11.1), but may not work in new version
(like version yade-0.12rc1). the version yade-0.12rc1 is also different
with the latest svn version.

I think this may be the reason for the crash.
--
This message was sent from Launchpad by the user
Jingsong Chen (https://launchpad.net/~chenjs923)
using the "Contact this team" link on the yade-users team page.
For more information see
https://help.launchpad.net/YourAccount/ContactingPeople

_______________________________________________
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users-oU9gvf+***@public.gmane.org
Unsubscribe : https://launchpad.net/~yade-users
More help : https://help.launchpad.net/ListHelp
Janek Kozicki
2009-07-02 06:50:56 UTC
Permalink
Jingsong Chen said: (by the date of Sat, 27 Jun 2009 14:58:45 -0000)
Post by Jingsong Chen
thank you for your suggestion, and i tried your method, but it still
crashed as before.
i also tried the simple FileGenerator examples in the code in latest
trunk. I should made some change in the code to let it through when i
compiled it (delete latticeLaw->tension_compression_different_stiffness
= true; add "false" in REGISTER_SERIALIZABLE(LatticeExampleSimple); ).
Then the compilation succeed.
I don't get it.. you picked files LatticeExampleSimple.[ch]pp from
trunk and compiled them with 0.12rc ? This mixing maybe works, but
shouldn't be done by unexperienced people. Either you are compiling
and using the svn treunk HEAD or 0.12rc. To try latest examples you
have to use HEAD.
Post by Jingsong Chen
For the simple example, once after I started the simulation, the four
control button in the Simulation tab of the Simulation Controller turn
grey, I can not stop or pause the simulation by myself. The simulation
will not stop, and there is no items in the OpenGL display (before i
started the simulation, i can see some node in the display).
I also found this in terminal.
"/home/daisy/build-0.12rc1/include/yade-0.12rc1/yade/core/MetaEngine2D.hpp:61
WARNING! dynamic cast of engine unit LatticeSet2LatticeBeams failed,
will use static_cast. Go figure why."
this message you can safely ignore. It has nothing to do with lattice
and is related to some dynamic casting in C++ in general, not with
lattice.
Post by Jingsong Chen
I think there may exist problems in version. some code can work in old
version (like version yade-0.11.1), but may not work in new version
(like version yade-0.12rc1). the version yade-0.12rc1 is also different
with the latest svn version.
I think this may be the reason for the crash.
you shouldn't be mixing different versions, unless you 100%
understand what you are doing.


Now, let me tell you about that OpenGL crash:

1. after you load simulation, you should be able to see a 3D view of
lattice sample which was generated. Click "center scene" if it's not
visible. Then you must see it. Not a single sphere, but a sample,
full of rods connected together.

2. then you have looked at your sample, you can click "right arrow"
button, to start simulation. It will start calculations, and it will
be displayed in 3D while being calculated.

3. "sync.display" checkbox may affect this, but in general it is a
known bug that simulation can crash *IF* the OpenGL window is opened
while calculating. I did no fix this, because I don't need to: all
serious calculation are ran *without* display. So to avoid crash,
simply close the view. After simulation is finished I am loading
automatically saved snapshots (using NullGUI) and look at the sample
in various stages of calculation.
This crash occurs, because it can happen that an element is being
drawn on the screen while simultaneously being deleted by the
calculating thread.

4. Run the simulation without OpenGL 3D view, by either just closing
it, or by running the simulation with NullGUI or python script. And
it will never crash and produce a correct physical result.


OpenGL is only used for debugging and is not useful for week-long
calculations, so it wasn't important enough for me to fix this crash.
Yes, I agree that it's very annoying.

best reagrds
--
Janek Kozicki |

_______________________________________________
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users-oU9gvf+***@public.gmane.org
Unsubscribe : https://launchpad.net/~yade-users
More help : https://help.launchpad.net/ListHelp
Janek Kozicki
2009-07-07 13:03:04 UTC
Permalink
陈敬松 said: (by the date of Sun, 5 Jul 2009 05:50:42 +0800)
For the lattice model, I closed the primary view and then run the simulation just as you suggested, but after about 3-4 seconds (iteration #304) the simulation still crashed. I don't know what's the problem.
first things first. Please make sure the we don't have any version
conflicts here.

Please delete your ~/.yade-* directories
Then please delete your ~/YADE/ (backup anything you might need later)
Then download again latest svn, compile it and run.

It is a common error that yade uses some old plugins from previous
versions, than are incompatibile, perhaps we would need some kind of
binary lib* versioning to prevent that. It became my habit to delete
config files and old binary files in case of some inexplicable
problems.

PS: please reply to the mailing list (not in private), it's better to
keep the discussion public.

best regards
--
Janek Kozicki |

_______________________________________________
Mailing list: https://launchpad.net/~yade-users
Post to : yade-***@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help : https://help.launchpad.net/ListHelp
Loading...