[f2py] ImportError when importing object created by F2PY, and
bug report
pearu at cens.ioc.ee
pearu at cens.ioc.ee
Thu Nov 3 13:00:18 EET 2005
On Tue, 1 Nov 2005 powrsurg at gmail.com wrote:
> The reason for the commented declaratins of mxbits, vst, and wst has
> to do with what I believe is a bug in F2PY. It seems that F2PY does
> not allow a previously declared parameter variable to be used twice
> within the declaration of another parameter varaible. For example,
>
> parameter (maxn=8000)
> parameter (mxbits=(maxn*(maxn+1)+29)/30)
>
> When looking at the _module.c file F2PY generates, it seems that F2PY
> replaces the first maxn with 8000, but does not do so for the second
> and thus creates an error. The only workaround for this was to comment
> out that line and replace it with the computed value of mxbits.
>
> ----------
>
> I hope including this all in one e-mail made sense. If someone could
> help me with this I would GREATLY apprecial it.
What f2py version are you using? I suggest trying f2py from CVS, if I
remember correctly then bugs related to evaluating parameters have been
fixed in CVS.
Pearu
More information about the f2py-users
mailing list