← Back to team overview

yade-dev team mailing list archive

Re: Interesting python usage

 

Oh, yes, I didnt do PyRun_SimpleString and pass my arguments as string, because the arguments change during run time.  The arguments are the id's of the bodies, which are currently handled by the Ig2Functor.  

Thanks,

Boon

----------------------------------------
> From: booncw@xxxxxxxxxxx
> To: yade-dev@xxxxxxxxxxxxxxxxxxx
> Date: Tue, 6 Apr 2010 02:49:50 +0800
> Subject: Re: [Yade-dev] Interesting python usage
>
>
> Indeed, I am abandoning the python one for the C one.  But the C library people are on Easter holiday and I'm not sure whether i'll get my license key anytime soon.
>
>
> Thanks,
>
> Boon
>
> ----------------------------------------
>> From: eudoxos@xxxxxxxx
>> To: yade-dev@xxxxxxxxxxxxxxxxxxx
>> Date: Mon, 5 Apr 2010 20:40:24 +0200
>> Subject: Re: [Yade-dev] Interesting python usage
>>
>>> The simulation is extremely slow. Is it because I am using a lot of O.bodies.state by assessing the getScene() pointer? Or is it because python module is compiled everytime i call it?
>> getScene is rather fast, it is just function returning pointer.
>> Importing the module will make it slow for sure. Why don't you import it
>> just once? The interpreter will remember it. I am not sure how to do
>> that with Python C API. I'd perhaps just run
>> PyRun_SimpleString("solverB.functionName(...)") passing args as string.
>>
>> (I thought you were using the c module now instead of python...?)
>>
>> v
>>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~yade-dev
>> Post to : yade-dev@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~yade-dev
>> More help : https://help.launchpad.net/ListHelp
>
> _________________________________________________________________
> Hotmail: Trusted email with powerful SPAM protection.
> https://signup.live.com/signup.aspx?id=60969
> _______________________________________________
> Mailing list: https://launchpad.net/~yade-dev
> Post to : yade-dev@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~yade-dev
> More help : https://help.launchpad.net/ListHelp
 		 	   		  
_________________________________________________________________
Hotmail: Powerful Free email with security by Microsoft.
https://signup.live.com/signup.aspx?id=60969


Follow ups

References