Hey,
Am 27.03.2017 um 16:09 schrieb Sebastian Berg:
> On Mon, 2017-03-27 at 13:06 +0200, Florian Lindner wrote:
>> Hey,
>>
>> I've timed the two versions, one basisfunction being a function:
>>
>> 1 loop, best of 3: 17.3 s per loop
>>
>> the other one, basisfunction being a list of functions:
>>
>
The best way to get good optimized code is to find it. Does this do what
you want?
https://docs.scipy.org/doc/scipy/reference/generated/scipy.interpolate.Rbf.html
For some advice here, first avoid loops in Python and instead stick to
ufuncs and broadcasting. It looks like the matrix is symmetri
On Mon, 2017-03-27 at 13:06 +0200, Florian Lindner wrote:
> Hey,
>
> I've timed the two versions, one basisfunction being a function:
>
> 1 loop, best of 3: 17.3 s per loop
>
> the other one, basisfunction being a list of functions:
>
> 1 loop, best of 3: 33.5 s per loop
>
> > To be honest, I
Hey,
I've timed the two versions, one basisfunction being a function:
1 loop, best of 3: 17.3 s per loop
the other one, basisfunction being a list of functions:
1 loop, best of 3: 33.5 s per loop
> To be honest, I am a bit surprised that its a problem, since "basis
> function" sounds a bit lik
On Sat, 2017-03-25 at 18:46 +0100, Florian Lindner wrote:
> Hello,
>
> I have this function:
>
> def eval_BF(self, meshA, meshB):
> """ Evaluates single BF or list of BFs on the meshes. """
> if type(self.basisfunction) is list:
> A = np.empty((len(meshA), len(meshB)))
Hello,
I have this function:
def eval_BF(self, meshA, meshB):
""" Evaluates single BF or list of BFs on the meshes. """
if type(self.basisfunction) is list:
A = np.empty((len(meshA), len(meshB)))
for i, row in enumerate(meshA):
for j, col in