← Back to team overview

yade-users team mailing list archive

Re: [Question #700165]: Functions in FEM-DEM

 

Question #700165 on Yade changed:
https://answers.launchpad.net/yade/+question/700165

    Status: Open => Answered

Jan Stránský proposed the following answer:
> This is my other question: Can FEM-DEM be installed on Ubunto 20.04
with newer versions of Python?

No.
IMO Ubuntu itself should not be a problem, but Python needs to be version 2 (as the versions of Yade and Oofem used uses only Python 2)
You can open an issue on the project sites if you have some terminal outputs e.g.

theoretically it is possible, but I do not have time for the update :-)
It would need new version of both Yade and Oofem, selecting a specific versions, create the patches to make it work together, .......

> Can I use __builtin__.someFunction inside engines when I implement the Pyrunner. For example, does this work?
> import __builtin__
>  PyRunner(iterPeriod=1, command="__builtin__.WheelPenetration()" ,label='checker')
> or do I need to declare it somewhere else?

Yes. But putting it into __builtin__, also this should work (not tested) without specifying __builtin__ explicitly:
PyRunner(iterPeriod=1, command="WheelPenetration()" ,label='checker')

Cheers
Jan

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.