Error running rotating-cilinder.py

Asked by Diego Fregolente

Dear all

I am very sorry if I am going to make a foolish question but, I just
started to use YADE and I am trying to run some of the examples.
Unfortunately , when I tried to run the program rotating-cilinder.py I
got the following error.

~/yade/examples/baraban$ yade -x rotating-cylinder.py
Welcome to Yade 0.60.3
TCP python prompt on localhost:9000, auth cookie `saskye'
XMLRPC info provider on http://localhost:21000

Running script rotating-cylinder.py
Generating cloud…
Traceback (most recent call last):
  File "/usr/bin/yade", line 152, in runScript
    execfile(script,globals())
  File "rotating-cylinder.py", line 49, in <module>

    NewtonIntegrator(damping=.3,gravity=(0,0,-1e3)), # gravity
artificially high, to make it faster going ;-)
AttributeError: No such attribute: gravity.

Please could you tell me how can I fix it?

with very best regards
Diego

--

Question information

Language:
English Edit question
Status:
Expired
For:
Yade Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Chiara Modenese (chiara-modenese) said :
#1

Hi Diego,

The error you mention occurs simply because you are using an older version of Yade where gravity was not yet an attribute of NewtonIntegrator class (exactly what the message tells you). You can either update to the latest version or use yade-daily from packages.

If, for any reason, you prefer to stick to the version you are currently working on, you should read something like this in the list of engines:

...
GravityEngine(gravity=(0,-1e3,0)),
NewtonIntegrator(),
...

HTH,
Chiara

On 29 Jun 2012, at 16:41, Diego Fregolente wrote:

> New question #201807 on Yade:
> https://answers.launchpad.net/yade/+question/201807
>
> Dear all
>
> I am very sorry if I am going to make a foolish question but, I just
> started to use YADE and I am trying to run some of the examples.
> Unfortunately , when I tried to run the program rotating-cilinder.py I
> got the following error.
>
> ~/yade/examples/baraban$ yade -x rotating-cylinder.py
> Welcome to Yade 0.60.3
> TCP python prompt on localhost:9000, auth cookie `saskye'
> XMLRPC info provider on http://localhost:21000
>
> Running script rotating-cylinder.py
> Generating cloud…
> Traceback (most recent call last):
> File "/usr/bin/yade", line 152, in runScript
> execfile(script,globals())
> File "rotating-cylinder.py", line 49, in <module>
>
> NewtonIntegrator(damping=.3,gravity=(0,0,-1e3)), # gravity
> artificially high, to make it faster going ;-)
> AttributeError: No such attribute: gravity.
>
> Please could you tell me how can I fix it?
>
> with very best regards
> Diego
>
> --
>
> You received this question notification because you are a member of
> yade-users, which is an answer contact for Yade.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~yade-users
> Post to : <email address hidden>
> Unsubscribe : https://launchpad.net/~yade-users
> More help : https://help.launchpad.net/ListHelp

Revision history for this message
Bruno Chareyre (bruno-chareyre) said :
#2

Where did you find the script? I suspect you are trying to run a recent
script with an older version of yade.
Try Yade 0.70 or check the example scripts from the doc package of the
same (0.60) version.

Revision history for this message
Diego Fregolente (diegofregolente) said :
#3

Hello Chiara and Chareyne

Thank you very much for your message and I am sorry for my late reply.
I downloaded yade following the instruction on the internet, namely
https://yade-dem.org/doc/installation.html ,
and the example which I was trying to run (rotating-cylinder.py) came with
yade in the the folder /home/user/yade/examples/baraban
That's why I assumed that it should work and when I got the error message I
thought it could be my mistake.

best regards
Diego

2012/6/29 Chiara Modenese <email address hidden>

> Your question #201807 on Yade changed:
> https://answers.launchpad.net/yade/+question/201807
>
> Status: Open => Answered
>
> Chiara Modenese proposed the following answer:
> Hi Diego,
>
> The error you mention occurs simply because you are using an older
> version of Yade where gravity was not yet an attribute of
> NewtonIntegrator class (exactly what the message tells you). You can
> either update to the latest version or use yade-daily from packages.
>
> If, for any reason, you prefer to stick to the version you are currently
> working on, you should read something like this in the list of engines:
>
> ...
> GravityEngine(gravity=(0,-1e3,0)),
> NewtonIntegrator(),
> ...
>
> HTH,
> Chiara
>
>
> On 29 Jun 2012, at 16:41, Diego Fregolente wrote:
>
> > New question #201807 on Yade:
> > https://answers.launchpad.net/yade/+question/201807
> >
> > Dear all
> >
> > I am very sorry if I am going to make a foolish question but, I just
> > started to use YADE and I am trying to run some of the examples.
> > Unfortunately , when I tried to run the program rotating-cilinder.py I
> > got the following error.
> >
> > ~/yade/examples/baraban$ yade -x rotating-cylinder.py
> > Welcome to Yade 0.60.3
> > TCP python prompt on localhost:9000, auth cookie `saskye'
> > XMLRPC info provider on http://localhost:21000
> >
> > Running script rotating-cylinder.py
> > Generating cloud…
> > Traceback (most recent call last):
> > File "/usr/bin/yade", line 152, in runScript
> > execfile(script,globals())
> > File "rotating-cylinder.py", line 49, in <module>
> >
> > NewtonIntegrator(damping=.3,gravity=(0,0,-1e3)), # gravity
> > artificially high, to make it faster going ;-)
> > AttributeError: No such attribute: gravity.
> >
> > Please could you tell me how can I fix it?
> >
> > with very best regards
> > Diego
> >
> > --
> >
> > You received this question notification because you are a member of
> > yade-users, which is an answer contact for Yade.
> >
> > _______________________________________________
> > Mailing list: https://launchpad.net/~yade-users
> > Post to : <email address hidden>
> > Unsubscribe : https://launchpad.net/~yade-users
> > More help : https://help.launchpad.net/ListHelp
>
> --
> If this answers your question, please go to the following page to let us
> know that it is solved:
> https://answers.launchpad.net/yade/+question/201807/+confirm?answer_id=0
>
> If you still need help, you can reply to this email or go to the
> following page to enter your feedback:
> https://answers.launchpad.net/yade/+question/201807
>
> You received this question notification because you asked the question.
>

--

Diego Fregolente Mendes de Oliveira
Institute for Multiscale Simulations - Friedrich-Alexander Universität
   Naegelsbachstrasse 49b D-91052 - Erlangen - Germany
            <email address hidden>
https://sites.google.com/site/diegofregolente/

Revision history for this message
Launchpad Janitor (janitor) said :
#4

This question was expired because it remained in the 'Open' state without activity for the last 15 days.