Yun,

Thank you for the report.

On Feb 24, 2012, at 9:20 PM, Yun Tao wrote:

> So when I first ran the script, this is what I get:
> 
> In [18]: run mesh2D-coupled.py
> ---------------------------------------------------------------------------
> ImportError                               Traceback (most recent call last)
> /Users/yuntao/FiPy/trunk/examples/cahnHilliard/mesh2D-coupled.py in <module>()
>     197 if __name__ == '__main__':
>     198     import fipy.tests.doctestPlus
> --> 199     exec(fipy.tests.doctestPlus._getScript())
>     200 
>     201     raw_input('finished')
> /Users/yuntao/FiPy/trunk/examples/cahnHilliard/mesh2D-coupled.py in <module>()
>      37 
>      38 
> ---> 39 
>      40 
>      41 
> /Users/yuntao/FiPy/trunk/examples/cahnHilliard/fipy/meshes/factoryMeshes.pyc 
> in Grid2D(dx, dy, nx, ny, Lx, Ly, overlap, communicator)
>     152     """
>     153 
> --> 154     from fipy.meshes import uniformGrid2D
>     155     from fipy.meshes import grid2D
>     156 



Here FiPy is being imported from your user directory:

> /Users/yuntao/FiPy/trunk/examples/cahnHilliard/fipy/meshes/factoryMeshes.pyc 
> in Grid2D(dx, dy, nx, ny, Lx, Ly, overlap, communicator)

but later, you are installing FiPy into site-packages:

> Yun-Taos-MacBook-Pro:trunk yuntao$ sudo python setup.py install


How was python finding FiPy before you did this? Did you alter your PYTHONPATH 
or something else?

We test this on multiple platforms with clean installs, so I really don't 
understand what you're seeing, but we do want to make sure there isn't a 
problem.

- Jon


> On Wed, Feb 22, 2012 at 10:32 AM, Jonathan Guyer <[email protected]> wrote:
> I don't understand. What changes did you have to make to UniformGrid2D? That 
> script is automatically (and successfully) tested every time trunk/ is 
> updated, so there should be no changes necessary. As for setting TKAgg, you 
> are better doing that in your .matplotlibrc 
> <http://matplotlib.sourceforge.net/users/customizing.html> than by hacking 
> the examples.
> 
> 
> On Feb 7, 2012, at 8:01 PM, Yun Tao wrote:
> 
> > It works! The only fix I have to make is to manually import and extend 
> > uniformGrid2D in meshes/__init__.py. Furthermore, in the script itself I 
> > imported matplotlib and used 'TKAgg' as the backend.

_______________________________________________
fipy mailing list
[email protected]
http://www.ctcms.nist.gov/fipy
  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]

Reply via email to