Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-10 Thread Michael Droettboom
Lorenzo Di Gregorio wrote:
 Well, that's exactly the problem: I just can't load some DLLs!
  
  import matplotlib._path

 Traceback (most recent call last):
   File pyshell#0, line 1, in module
 import matplotlib._path
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht 
 gefunden.
  import matplotlib._delaunay
  import matplotlib._image

 Traceback (most recent call last):
   File pyshell#2, line 1, in module
 import matplotlib._image
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht 
 gefunden.

 I have run python -vv, it tries also ..._path but does not load it, so 
 I think it might be a linking problem.
 I've noticed that _delaunay.cpp has a PyMODINIT_FUNC 
 init_delaunay(void) while _path.cpp has just a void init_path(void).
If you make that change, does it work?

Mike
  
 Best Regards,
 Lorenzo
  
 On 4/9/09, *Michael Droettboom* md...@stsci.edu 
 mailto:md...@stsci.edu wrote:

 Can you send us the output of this Python session to help us
 debug?  I'm curious what symbols *are* in there.

  import matplotlib._path
  dir(matplotlib._path)
 ['__doc__', '__file__', '__name__', 'affine_transform',
 'clip_path_to_rect', 'convert_path_to_polygons',
 'count_bboxes_overlapping_bbox', 'get_path_collection_extents',
 'get_path_extents', 'path_in_path', 'path_intersects_path',
 'point_in_path', 'point_in_path_collection', 'point_on_path',
 'update_path_extents']
 

 Cheers,
 Mike

 Lorenzo Di Gregorio wrote:

 On Thu, Apr 9, 2009 at 7:06 AM, Andrew Straw
 straw...@astraw.com mailto:straw...@astraw.com
 mailto:straw...@astraw.com mailto:straw...@astraw.com wrote:

Lorenzo Di Gregorio wrote:
 Hello,

 I've tried to build matplotlib 0.98.5.2 for Python 2.6
 under Windows
 (Win2k) using MinGW and win32_static.  After a few fixes, the
 compilation and install appear to be ok, but I've got
 stuck at
 importing matplotlib._path (see transcript below).
 Any suggestions on what is going wrong and how to fix it?

   File
 C:\Python26\lib\site-packages\matplotlib\artist.py, line 5,
 in module

 from transforms import Bbox, IdentityTransform,
 TransformedBbox,
 Transformed
 Path
   File
 C:\Python26\lib\site-packages\matplotlib\transforms.py,
line
 34, in mo
 dule
 from matplotlib._path import affine_transform
 ImportError: DLL load failed: Die angegebene Prozedur
 wurde nicht
 gefunden.

Did _path.cpp get compiled to a .pyd OK? (Do you have
C:\PYTHON26\Lib\site-packages\matplotlib\_path.pyd
 installed? -- I
guess
that's where it would be... Not running Python on Windows,
 though, I
could be off a bit.)


 Yes, that's compiled and installed at the location you mentioned.
 In fact I have no idea what is wrong with that.
 How does a .pyd reference a DLL and what is it supposed to load?
  
And, as a hint to anyone else attempting to debug this: the
 above
traceback means The given procedure was not found. (And
 Lorenzo Di
Gregorio doesn't sound like a very German name to me, so
 why your
computer is speaking German I don't know... :)


 Right, I don't know either why I haven't switched it already
 ;-) But mitigating circumstances for lazyness are that German
 is my second language, my wife is German, I live and work in
 Germany etc.

I do find something nice about running Python 2.6 under Win2k,
though...


 ... under Linux it was too easy ;-P (my company runs Win2k!)
 
 

 
 --
 This SF.net email is sponsored by:
 High Quality Requirements in a Collaborative Environment.
 Download a free trial of Rational Requirements Composer Now!
 http://p.sf.net/sfu/www-ibm-com
 
 

 ___
 Matplotlib-users mailing list
 Matplotlib-users@lists.sourceforge.net
 mailto:Matplotlib-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/matplotlib-users
  


 -- 
 Michael Droettboom
 Science Software Branch
 Operations and Engineering Division
 Space Telescope Science Institute
 Operated by AURA for NASA



-- 
Michael Droettboom
Science Software Branch

Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-10 Thread Lorenzo Di Gregorio
On 4/10/09, Michael Droettboom md...@stsci.edu wrote:

 Lorenzo Di Gregorio wrote:

 Well, that's exactly the problem: I just can't load some DLLs!
   import matplotlib._path

 Traceback (most recent call last):
  File pyshell#0, line 1, in module
import matplotlib._path
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.
  import matplotlib._delaunay
  import matplotlib._image

 Traceback (most recent call last):
  File pyshell#2, line 1, in module
import matplotlib._image
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.

 I have run python -vv, it tries also ..._path but does not load it, so I
 think it might be a linking problem.
 I've noticed that _delaunay.cpp has a PyMODINIT_FUNC init_delaunay(void)
 while _path.cpp has just a void init_path(void).

 If you make that change, does it work?


No, I tried.

I have also tried to start python -vv.
For _delaunay I get a correct import.

# trying C:\Python26\lib\site-packages\matplotlib\_delaunay.pyd
import matplotlib._delaunay # dynamically loaded from
C:\Python26\lib\site-packages\matplotlib\_delaunay.pyd

For _path and _image I get

 import matplotlib._path
# trying C:\Python26\lib\site-packages\matplotlib\_path.pyd
Traceback (most recent call last):
  File stdin, line 1, in module
ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.
 import matplotlib._image
# trying C:\Python26\lib\site-packages\matplotlib\_image.pyd
Traceback (most recent call last):
  File stdin, line 1, in module
ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.

So Python checks the right place but then concludes that the DLL is not
there.  I guess something goes wrong with the linking, but in fact I do not
know how to write a DLL for Python and I'm stuck now.
I have checked that the compilation was ok and the rest of the installation
(GTK+ etc) is ok.  I can import matplotlib itself.  In the packages I had
only one package to patch: I think gpobjects had a reference to @FFI_LIB@.
This was getting through pkg-config and stopping the compilation, so I have
removed it.

... HELP! ;-)

Regards,
Lorenzo
--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-10 Thread Lorenzo Di Gregorio
Ouch, it looks like MinGW and Python do not fit 100% to each other.
Please check out this bug report:

http://bugs.python.org/issue3308

Basically MinGW erroneously ships a .lib saying localtime is in
MSVCR90.DLL when it isn't.  That means there is no link failure but the
*pyd* will fail to load without information as to why.  Fixing the .lib
means that localtime is picked up from MSVCRT.DLL (ie no version in
name) and everything appears to work well.


On 4/10/09, Lorenzo Di Gregorio lorenzo.digrego...@gmail.com wrote:

 On 4/10/09, Michael Droettboom md...@stsci.edu wrote:

 Lorenzo Di Gregorio wrote:

 Well, that's exactly the problem: I just can't load some DLLs!
   import matplotlib._path

 Traceback (most recent call last):
  File pyshell#0, line 1, in module
import matplotlib._path
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.
  import matplotlib._delaunay
  import matplotlib._image

 Traceback (most recent call last):
  File pyshell#2, line 1, in module
import matplotlib._image
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.

 I have run python -vv, it tries also ..._path but does not load it, so I
 think it might be a linking problem.
 I've noticed that _delaunay.cpp has a PyMODINIT_FUNC
 init_delaunay(void) while _path.cpp has just a void init_path(void).

 If you make that change, does it work?


 No, I tried.

 I have also tried to start python -vv.
 For _delaunay I get a correct import.

 # trying C:\Python26\lib\site-packages\matplotlib\_delaunay.pyd
 import matplotlib._delaunay # dynamically loaded from
 C:\Python26\lib\site-packages\matplotlib\_delaunay.pyd

 For _path and _image I get

  import matplotlib._path
 # trying C:\Python26\lib\site-packages\matplotlib\_path.pyd
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.
  import matplotlib._image
 # trying C:\Python26\lib\site-packages\matplotlib\_image.pyd
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.

 So Python checks the right place but then concludes that the DLL is not
 there.  I guess something goes wrong with the linking, but in fact I do not
 know how to write a DLL for Python and I'm stuck now.
 I have checked that the compilation was ok and the rest of the installation
 (GTK+ etc) is ok.  I can import matplotlib itself.  In the packages I had
 only one package to patch: I think gpobjects had a reference to @FFI_LIB@.
 This was getting through pkg-config and stopping the compilation, so I have
 removed it.

 ... HELP! ;-)

 Regards,
 Lorenzo

--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-09 Thread Lorenzo Di Gregorio
On Thu, Apr 9, 2009 at 7:06 AM, Andrew Straw straw...@astraw.com wrote:

 Lorenzo Di Gregorio wrote:
  Hello,
 
  I've tried to build matplotlib 0.98.5.2 for Python 2.6 under Windows
  (Win2k) using MinGW and win32_static.  After a few fixes, the
  compilation and install appear to be ok, but I've got stuck at
  importing matplotlib._path (see transcript below).
  Any suggestions on what is going wrong and how to fix it?
 
File C:\Python26\lib\site-packages\matplotlib\artist.py, line 5,
  in module
 
  from transforms import Bbox, IdentityTransform, TransformedBbox,
  Transformed
  Path
File C:\Python26\lib\site-packages\matplotlib\transforms.py, line
  34, in mo
  dule
  from matplotlib._path import affine_transform
  ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
  gefunden.
 
 Did _path.cpp get compiled to a .pyd OK? (Do you have
 C:\PYTHON26\Lib\site-packages\matplotlib\_path.pyd installed? -- I guess
 that's where it would be... Not running Python on Windows, though, I
 could be off a bit.)


Yes, that's compiled and installed at the location you mentioned.
In fact I have no idea what is wrong with that.
How does a .pyd reference a DLL and what is it supposed to load?


 And, as a hint to anyone else attempting to debug this: the above
 traceback means The given procedure was not found. (And Lorenzo Di
 Gregorio doesn't sound like a very German name to me, so why your
 computer is speaking German I don't know... :)


Right, I don't know either why I haven't switched it already ;-) But
mitigating circumstances for lazyness are that German is my second language,
my wife is German, I live and work in Germany etc.

I do find something nice about running Python 2.6 under Win2k, though...


... under Linux it was too easy ;-P (my company runs Win2k!)
--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-09 Thread Michael Droettboom
Can you send us the output of this Python session to help us debug?  I'm 
curious what symbols *are* in there.

  import matplotlib._path
  dir(matplotlib._path)
['__doc__', '__file__', '__name__', 'affine_transform', 
'clip_path_to_rect', 'convert_path_to_polygons', 
'count_bboxes_overlapping_bbox', 'get_path_collection_extents', 
'get_path_extents', 'path_in_path', 'path_intersects_path', 
'point_in_path', 'point_in_path_collection', 'point_on_path', 
'update_path_extents']
 

Cheers,
Mike

Lorenzo Di Gregorio wrote:
 On Thu, Apr 9, 2009 at 7:06 AM, Andrew Straw straw...@astraw.com 
 mailto:straw...@astraw.com wrote:

 Lorenzo Di Gregorio wrote:
  Hello,
 
  I've tried to build matplotlib 0.98.5.2 for Python 2.6 under Windows
  (Win2k) using MinGW and win32_static.  After a few fixes, the
  compilation and install appear to be ok, but I've got stuck at
  importing matplotlib._path (see transcript below).
  Any suggestions on what is going wrong and how to fix it?
 
File C:\Python26\lib\site-packages\matplotlib\artist.py, line 5,
  in module
 
  from transforms import Bbox, IdentityTransform, TransformedBbox,
  Transformed
  Path
File C:\Python26\lib\site-packages\matplotlib\transforms.py,
 line
  34, in mo
  dule
  from matplotlib._path import affine_transform
  ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
  gefunden.
 
 Did _path.cpp get compiled to a .pyd OK? (Do you have
 C:\PYTHON26\Lib\site-packages\matplotlib\_path.pyd installed? -- I
 guess
 that's where it would be... Not running Python on Windows, though, I
 could be off a bit.)


 Yes, that's compiled and installed at the location you mentioned.
 In fact I have no idea what is wrong with that.
 How does a .pyd reference a DLL and what is it supposed to load?
  

 And, as a hint to anyone else attempting to debug this: the above
 traceback means The given procedure was not found. (And Lorenzo Di
 Gregorio doesn't sound like a very German name to me, so why your
 computer is speaking German I don't know... :)


 Right, I don't know either why I haven't switched it already ;-) But 
 mitigating circumstances for lazyness are that German is my second 
 language, my wife is German, I live and work in Germany etc.

 I do find something nice about running Python 2.6 under Win2k,
 though...


 ... under Linux it was too easy ;-P (my company runs Win2k!)
 

 --
 This SF.net email is sponsored by:
 High Quality Requirements in a Collaborative Environment.
 Download a free trial of Rational Requirements Composer Now!
 http://p.sf.net/sfu/www-ibm-com
 

 ___
 Matplotlib-users mailing list
 Matplotlib-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/matplotlib-users
   

-- 
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA


--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-09 Thread Lorenzo Di Gregorio
Well, that's exactly the problem: I just can't load some DLLs!

 import matplotlib._path

Traceback (most recent call last):
  File pyshell#0, line 1, in module
import matplotlib._path
ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.
 import matplotlib._delaunay
 import matplotlib._image

Traceback (most recent call last):
  File pyshell#2, line 1, in module
import matplotlib._image
ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.
I have run python -vv, it tries also ..._path but does not load it, so I
think it might be a linking problem.
I've noticed that _delaunay.cpp has a PyMODINIT_FUNC init_delaunay(void)
while _path.cpp has just a void init_path(void).

Best Regards,
Lorenzo

On 4/9/09, Michael Droettboom md...@stsci.edu wrote:

 Can you send us the output of this Python session to help us debug?  I'm
 curious what symbols *are* in there.

  import matplotlib._path
  dir(matplotlib._path)
 ['__doc__', '__file__', '__name__', 'affine_transform',
 'clip_path_to_rect', 'convert_path_to_polygons',
 'count_bboxes_overlapping_bbox', 'get_path_collection_extents',
 'get_path_extents', 'path_in_path', 'path_intersects_path', 'point_in_path',
 'point_in_path_collection', 'point_on_path', 'update_path_extents']
 

 Cheers,
 Mike

 Lorenzo Di Gregorio wrote:

 On Thu, Apr 9, 2009 at 7:06 AM, Andrew Straw straw...@astraw.commailto:
 straw...@astraw.com wrote:

Lorenzo Di Gregorio wrote:
 Hello,

 I've tried to build matplotlib 0.98.5.2 for Python 2.6 under Windows
 (Win2k) using MinGW and win32_static.  After a few fixes, the
 compilation and install appear to be ok, but I've got stuck at
 importing matplotlib._path (see transcript below).
 Any suggestions on what is going wrong and how to fix it?

   File C:\Python26\lib\site-packages\matplotlib\artist.py, line 5,
 in module

 from transforms import Bbox, IdentityTransform, TransformedBbox,
 Transformed
 Path
   File C:\Python26\lib\site-packages\matplotlib\transforms.py,
line
 34, in mo
 dule
 from matplotlib._path import affine_transform
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.

Did _path.cpp get compiled to a .pyd OK? (Do you have
C:\PYTHON26\Lib\site-packages\matplotlib\_path.pyd installed? -- I
guess
that's where it would be... Not running Python on Windows, though, I
could be off a bit.)


 Yes, that's compiled and installed at the location you mentioned.
 In fact I have no idea what is wrong with that.
 How does a .pyd reference a DLL and what is it supposed to load?

And, as a hint to anyone else attempting to debug this: the above
traceback means The given procedure was not found. (And Lorenzo Di
Gregorio doesn't sound like a very German name to me, so why your
computer is speaking German I don't know... :)


 Right, I don't know either why I haven't switched it already ;-) But
 mitigating circumstances for lazyness are that German is my second language,
 my wife is German, I live and work in Germany etc.

I do find something nice about running Python 2.6 under Win2k,
though...


 ... under Linux it was too easy ;-P (my company runs Win2k!)
 


 --
 This SF.net email is sponsored by:
 High Quality Requirements in a Collaborative Environment.
 Download a free trial of Rational Requirements Composer Now!
 http://p.sf.net/sfu/www-ibm-com
 

 ___
 Matplotlib-users mailing list
 Matplotlib-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/matplotlib-users



 --
 Michael Droettboom
 Science Software Branch
 Operations and Engineering Division
 Space Telescope Science Institute
 Operated by AURA for NASA


--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-08 Thread Lorenzo Di Gregorio
Hello,

I've tried to build matplotlib 0.98.5.2 for Python 2.6 under Windows
(Win2k) using MinGW and win32_static.  After a few fixes, the compilation
and install appear to be ok, but I've got stuck at importing
matplotlib._path (see transcript below).
Any suggestions on what is going wrong and how to fix it?

C:\My Programs\matplotlib-0.98.5.2ipython -pylab
C:\Python26\lib\site-packages\IPython\Magic.py:38: DeprecationWarning: the
sets
module is deprecated
  from sets import Set
Traceback (most recent call last):
  File C:\Python26\scripts\ipython.py, line 28, in module
IPython.Shell.start().mainloop()
  File C:\Python26\Lib\site-packages\IPython\Shell.py, line 1233, in start
return shell(user_ns = user_ns)
  File C:\Python26\Lib\site-packages\IPython\Shell.py, line 1108, in
__init__
shell_class=MatplotlibMTShell)
  File C:\Python26\Lib\site-packages\IPython\Shell.py, line 793, in
__init__
on_kill=[mainquit])
  File C:\Python26\Lib\site-packages\IPython\ipmaker.py, line 103, in
make_IPy
thon
embedded=embedded,**kw)
  File C:\Python26\Lib\site-packages\IPython\Shell.py, line 639, in
__init__
user_ns,user_global_ns,b2 =
self._matplotlib_config(name,user_ns,user_global
_ns)
  File C:\Python26\Lib\site-packages\IPython\Shell.py, line 559, in
_matplotli
b_config
import matplotlib.pylab as pylab
  File C:\Python26\lib\site-packages\matplotlib\pylab.py, line 206, in
module

from matplotlib import mpl  # pulls in most modules
  File C:\Python26\lib\site-packages\matplotlib\mpl.py, line 1, in
module
from matplotlib import artist
  File C:\Python26\lib\site-packages\matplotlib\artist.py, line 5, in
module

from transforms import Bbox, IdentityTransform, TransformedBbox,
Transformed
Path
  File C:\Python26\lib\site-packages\matplotlib\transforms.py, line 34, in
mo
dule
from matplotlib._path import affine_transform
ImportError: DLL load failed: Die angegebene Prozedur wurde nicht gefunden.

C:\My Programs\matplotlib-0.98.5.2
--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] matplotlib._path failed on windows build for Python 2.6

2009-04-08 Thread Andrew Straw
Lorenzo Di Gregorio wrote:
 Hello,
  
 I've tried to build matplotlib 0.98.5.2 for Python 2.6 under Windows
 (Win2k) using MinGW and win32_static.  After a few fixes, the
 compilation and install appear to be ok, but I've got stuck at
 importing matplotlib._path (see transcript below).
 Any suggestions on what is going wrong and how to fix it?

   File C:\Python26\lib\site-packages\matplotlib\artist.py, line 5,
 in module

 from transforms import Bbox, IdentityTransform, TransformedBbox,
 Transformed
 Path
   File C:\Python26\lib\site-packages\matplotlib\transforms.py, line
 34, in mo
 dule
 from matplotlib._path import affine_transform
 ImportError: DLL load failed: Die angegebene Prozedur wurde nicht
 gefunden.

Did _path.cpp get compiled to a .pyd OK? (Do you have
C:\PYTHON26\Lib\site-packages\matplotlib\_path.pyd installed? -- I guess
that's where it would be... Not running Python on Windows, though, I
could be off a bit.)

And, as a hint to anyone else attempting to debug this: the above
traceback means The given procedure was not found. (And Lorenzo Di
Gregorio doesn't sound like a very German name to me, so why your
computer is speaking German I don't know... :)

I do find something nice about running Python 2.6 under Win2k, though...

Andrew

--
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users