[SciPy-user] [f2py] hide ?
Thu Apr 26 08:57:37 CDT 2007
Here are some things that could be wrong.
1. You declare a as intent(in, out), this means that a is modified in place,
ie, the subroutine does not return a value.
>>> essai.essai(a, b, KW, nx, ny, nz)
will hence return none.
2. Declare the dimension explicitely in the cf2py comments
cf2py integer dimension(nx,ny,nz), intent(in) :: b
3. If you want to hide the shape integers, you need to tell it to.
cf2py integer, intent(hide) :: nx=shape(b,0)
cf2py integer, intent(hide) :: ny=shape(b,1)
cf2py integer, intent(hide) :: nz=shape(b,2)
My advice would be to start with the plain fortran function without cf2py
comments, and add them one at a time.
2007/4/26, fred <email@example.com>:
> fred a écrit :
> > Ok, let's talk about array now ;-)
> > The following sample code fails if I use nvx arg in essai(),
> Nobody can help me on this issue, please ?
> SciPy-user mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-user