Re: [Numpy-discussion] local variable referenced before assignment

2011-05-31 Thread Edoardo Pasca
On Tue, May 31, 2011 at 11:34 AM, Vincent Schut wrote: > On 05/31/2011 11:04 AM, Edoardo Pasca wrote: >> UnboundLocalError: local variable 'maxFastSampling' referenced before >> assignment >> >> I wonder whether you see any way that the maxFastSampling variable >> might not be set. > > Edo, > >

Re: [Numpy-discussion] local variable referenced before assignment

2011-05-31 Thread Vincent Schut
On 05/31/2011 11:04 AM, Edoardo Pasca wrote: > Dear all, > > sometimes I encounter the problem that calling many times a function > it happens that some local variables are not defined and the procedure > crashes. > > For example I have a function defined as > > def procedure(tt, Ctissue, WeinmannF

[Numpy-discussion] local variable referenced before assignment

2011-05-31 Thread Edoardo Pasca
Dear all, sometimes I encounter the problem that calling many times a function it happens that some local variables are not defined and the procedure crashes. For example I have a function defined as def procedure(tt, Ctissue, WeinmannFit, bodyWeight): for maxFastSampling in range(1,len(tt))