|
From: Brice T. <B.P...@ci...> - 2005-06-14 10:42:02
|
I've just finished to install matplotlib on mac os X panther and when I
try to import pylab, i have got the following error:
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/pylab.py", line 1, in ?
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/pylab.py", line 195, in ?
from axes import Axes, PolarAxes
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axes.py", line 14, in ?
from axis import XAxis, YAxis
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axis.py", line 21, in ?
from font_manager import FontProperties
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 982, in ?
fontManager = FontManager()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 826, in __init__
rebuild()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 819, in rebuild
self.ttfdict = createFontDict(self.ttffiles)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 458, in createFontDict
prop = ttfFontProperty(font)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 271, in ttfFontProperty
sfnt = font.get_sfnt()
RuntimeError: No SFNT name table
Could anyone help with this issue? Many thanks
Brice
|
|
From: Brice T. <B.P...@ci...> - 2005-06-14 11:45:10
|
I've just finished to install matplotlib on mac os X panther and when I
try to import pylab, i have got the following error:
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/pylab.py", line 1, in ?
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/pylab.py", line 195, in ?
from axes import Axes, PolarAxes
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axes.py", line 14, in ?
from axis import XAxis, YAxis
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axis.py", line 21, in ?
from font_manager import FontProperties
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 982, in ?
fontManager = FontManager()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 826, in __init__
rebuild()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 819, in rebuild
self.ttfdict = createFontDict(self.ttffiles)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 458, in createFontDict
prop = ttfFontProperty(font)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 271, in ttfFontProperty
sfnt = font.get_sfnt()
RuntimeError: No SFNT name table
Could anyone help with this issue? Many thanks
Brice
Brice Thurin
Department of Optometry and Visual Science
City University, Northampton Square
London, EC1V 0HB, UK.
http://www.city.ac.uk/optometry/Luis/myresearch/Research/
scatteringproper.html
http://www.sharpeye.org/
Tel: +44 (0)20 7040 4157
Fax: +44(0)20 7040 8355
e-mail: B.P...@ci...
|
|
From: Michael T. <mic...@gm...> - 2005-06-14 14:09:07
|
Hi,
(I am assuming you've built your own copy of matplotlib)
This usually happens when matplotlib's ft2font.so links against OS X's
copy of freetype, instead of a newer copy (which you have to install).
The copy of freetype with OS X is too old to figure out some of the
newer fonts (especially asian ones) installed on OS X.
You can verify that it is linked against
/usr/X11R6/lib/libfreetype.6.dylib using:
$ otool -L /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/=
site-packages/matplotlib/ft2font.so
/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packag=
es/matplotlib/ft2font.so:
/opt/local/lib/libfreetype.6.dylib (compatibility version
10.0.0, current version 10.7.0)
...
(In my case I've linked against darwinports' freetype)
AFAIK matplotlib will find fink's freetype automatically when
building, if you install fink from http://fink.sourceforge.net/ and
install freetype219 ("$ fink install freetype219"), then rebuild
matplotlib all should be well.
Michael
On 6/14/05, Brice Thurin <B.P...@ci...> wrote:
> I've just finished to install matplotlib on mac os X panther and when I
> try to import pylab, i have got the following error:
>=20
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/pylab.py", line 1, in ?
> from matplotlib.pylab import *
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/pylab.py", line 195, in ?
> from axes import Axes, PolarAxes
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/axes.py", line 14, in ?
> from axis import XAxis, YAxis
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/axis.py", line 21, in ?
> from font_manager import FontProperties
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/font_manager.py", line 982, in ?
> fontManager =3D FontManager()
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/font_manager.py", line 826, in __init__
> rebuild()
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/font_manager.py", line 819, in rebuild
> self.ttfdict =3D createFontDict(self.ttffiles)
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/font_manager.py", line 458, in createFontDict
> prop =3D ttfFontProperty(font)
> File
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> packages/matplotlib/font_manager.py", line 271, in ttfFontProperty
> sfnt =3D font.get_sfnt()
> RuntimeError: No SFNT name table
>=20
>=20
> Could anyone help with this issue? Many thanks
>=20
> Brice
>=20
>=20
>=20
> -------------------------------------------------------
> This SF.Net email is sponsored by: NEC IT Guy Games. How far can you sho=
tput
> a projector? How fast can you ride your desk chair down the office luge t=
rack?
> If you want to score the big prize, get to know the little guy.
> Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=3D20
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
|
|
From: Chris B. <Chr...@no...> - 2005-06-14 16:28:22
Attachments:
BuildingMatplotlib.txt
|
Michael Twomey wrote: > AFAIK matplotlib will find fink's freetype automatically when > building, if you install fink from http://fink.sourceforge.net/ and > install freetype219 ("$ fink install freetype219"), then rebuild > matplotlib all should be well. You have a couple other options as well: darwinports freetype ( I haven't used it, but it should exist) the freetype tarball. I ready-to-go binary installer. There is an older one at pythonmac.org/packages, and I'm in the process of building some newer ones. I've enclosed my instructions on how to build them here, if you want to do it yourself. If you find anything errors, or things that need clarifying, please let me know. It is a draft, so don't be too critical. -Chris -- Christopher Barker, Ph.D. Oceanographer NOAA/OR&R/HAZMAT (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |
|
From: Brice T. <B.P...@ci...> - 2005-06-15 11:26:37
|
Thank you for your response. I have been trying to follow your instruction, but still have the same error message. Matplotlib's ft2font.so links against /usr/local/lib/libfreetype.6.dylib (compatibility version 10.0.0, current version 10.8.0), which should be alright (I check with the install of freetype it has been installed in this folder). could you give anymore hints... Thanks Brice On 14 Jun 2005, at 15:09, Michael Twomey wrote: > Hi, > > (I am assuming you've built your own copy of matplotlib) > > This usually happens when matplotlib's ft2font.so links against OS X's > copy of freetype, instead of a newer copy (which you have to install). > The copy of freetype with OS X is too old to figure out some of the > newer fonts (especially asian ones) installed on OS X. > > You can verify that it is linked against > /usr/X11R6/lib/libfreetype.6.dylib using: > > $ otool -L > /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- > packages/matplotlib/ft2font.so > /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- > packages/matplotlib/ft2font.so: > /opt/local/lib/libfreetype.6.dylib (compatibility version > 10.0.0, current version 10.7.0) > ... > (In my case I've linked against darwinports' freetype) > > AFAIK matplotlib will find fink's freetype automatically when > building, if you install fink from http://fink.sourceforge.net/ and > install freetype219 ("$ fink install freetype219"), then rebuild > matplotlib all should be well. > > Michael > > On 6/14/05, Brice Thurin <B.P...@ci...> wrote: >> I've just finished to install matplotlib on mac os X panther and when >> I >> try to import pylab, i have got the following error: >> >> Traceback (most recent call last): >> File "<stdin>", line 1, in ? >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/pylab.py", line 1, in ? >> from matplotlib.pylab import * >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/pylab.py", line 195, in ? >> from axes import Axes, PolarAxes >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/axes.py", line 14, in ? >> from axis import XAxis, YAxis >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/axis.py", line 21, in ? >> from font_manager import FontProperties >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/font_manager.py", line 982, in ? >> fontManager = FontManager() >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/font_manager.py", line 826, in __init__ >> rebuild() >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/font_manager.py", line 819, in rebuild >> self.ttfdict = createFontDict(self.ttffiles) >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/font_manager.py", line 458, in createFontDict >> prop = ttfFontProperty(font) >> File >> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- >> packages/matplotlib/font_manager.py", line 271, in ttfFontProperty >> sfnt = font.get_sfnt() >> RuntimeError: No SFNT name table >> >> >> Could anyone help with this issue? Many thanks >> >> Brice >> >> >> >> ------------------------------------------------------- >> This SF.Net email is sponsored by: NEC IT Guy Games. How far can you >> shotput >> a projector? How fast can you ride your desk chair down the office >> luge track? >> If you want to score the big prize, get to know the little guy. >> Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20 >> _______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> > > > ------------------------------------------------------- > This SF.Net email is sponsored by: NEC IT Guy Games. How far can you > shotput > a projector? How fast can you ride your desk chair down the office > luge track? > If you want to score the big prize, get to know the little guy. > Play to win an NEC 61" plasma display: http://www.necitguy.com/?r > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > Brice Thurin Department of Optometry and Visual Science City University, Northampton Square London, EC1V 0HB, UK. http://www.city.ac.uk/optometry/Luis/myresearch/Research/ scatteringproper.html http://www.sharpeye.org/ Tel: +44 (0)20 7040 4157 Fax: +44(0)20 7040 8355 e-mail: B.P...@ci... |
|
From: Michael T. <mic...@gm...> - 2005-06-15 13:03:24
|
Rats, this looks like it should work.=20 I'd recommend trying Chris's binary package when he gets it done (Chris, do you need any help on that front?). You could try a completely fresh rebuild: 1. Completely remove /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site- > packages/matplotlib/ 2. Completely remove the build directory from your matplotlib-0.81 source t= ree 3. try the setup.py build again It's possible there is something which didn't cleanly relink itself. Failing that it's probably going to be one of those annoying retry step by step moments. Michael On 6/15/05, Brice Thurin <B.P...@ci...> wrote: > Thank you for your response. > I have been trying to follow your instruction, but still have the same > error message. Matplotlib's ft2font.so links against > /usr/local/lib/libfreetype.6.dylib (compatibility version 10.0.0, > current version 10.8.0), which should be alright (I check with the > install of freetype it has been installed in this folder). >=20 > could you give anymore hints... >=20 > Thanks > Brice > |
|
From: Chris B. <Chr...@no...> - 2005-06-15 18:00:11
|
Michael Twomey wrote:
> I'd recommend trying Chris's binary package when he gets it done
> (Chris, do you need any help on that front?).
Well, not for what I intend to do, but I wasn't planning on building in
PyGTK support. In a way, doing that is contrary to my goal, which is a
package that can be installed on a stock OS-X (except Numerix, of
course). i.e. fink-free.
However, it would probably work fine to have GTK compiled into the
binary, and it shouldn't break any of the other back-ends...it just
wouldn't work with PyGTK if PyGTK wasn't there, which is kind of obvious.
So, if someone want to build a package with PyGTK support, I'll send you
what I have to docs, and you can go to it. I'd love for there to be only
one "official" package, so if someone makes a superset of mine, I won't
distribute mine.
-Chris
--
Christopher Barker, Ph.D.
Oceanographer
NOAA/OR&R/HAZMAT (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chr...@no...
|
|
From: Brice T. <B.P...@ci...> - 2005-07-06 14:35:15
|
Hello,
I still have the same error, same with the binary package:
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/pylab.py", line 1, in ?
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/pylab.py", line 198, in ?
from axes import Axes, PolarAxes
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axes.py", line 14, in ?
from axis import XAxis, YAxis
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/axis.py", line 21, in ?
from font_manager import FontProperties
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 982, in ?
fontManager = FontManager()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 826, in __init__
rebuild()
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 819, in rebuild
self.ttfdict = createFontDict(self.ttffiles)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 458, in createFontDict
prop = ttfFontProperty(font)
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py", line 271, in ttfFontProperty
sfnt = font.get_sfnt()
RuntimeError: No SFNT name table
Many Thanks for your help
Brice
On 15 Jun 2005, at 18:58, Chris Barker wrote:
>
> Michael Twomey wrote:
>> I'd recommend trying Chris's binary package when he gets it done
>> (Chris, do you need any help on that front?).
>
> Well, not for what I intend to do, but I wasn't planning on building
> in PyGTK support. In a way, doing that is contrary to my goal, which
> is a package that can be installed on a stock OS-X (except Numerix, of
> course). i.e. fink-free.
>
> However, it would probably work fine to have GTK compiled into the
> binary, and it shouldn't break any of the other back-ends...it just
> wouldn't work with PyGTK if PyGTK wasn't there, which is kind of
> obvious.
>
> So, if someone want to build a package with PyGTK support, I'll send
> you what I have to docs, and you can go to it. I'd love for there to
> be only one "official" package, so if someone makes a superset of
> mine, I won't distribute mine.
>
> -Chris
>
>
> --
> Christopher Barker, Ph.D.
> Oceanographer
>
> NOAA/OR&R/HAZMAT (206) 526-6959 voice
> 7600 Sand Point Way NE (206) 526-6329 fax
> Seattle, WA 98115 (206) 526-6317 main reception
>
> Chr...@no...
>
>
> -------------------------------------------------------
> SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
> from IBM. Find simple to follow Roadmaps, straightforward articles,
> informative Webcasts and more! Get everything you need to get up to
> speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>
|
|
From: John H. <jdh...@ac...> - 2005-07-06 14:51:13
|
>>>>> "Brice" == Brice Thurin <B.P...@ci...> writes:
Brice> packages/matplotlib/font_manager.py", line 458, in
Brice> createFontDict prop = ttfFontProperty(font) File
Brice> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
Brice> packages/matplotlib/font_manager.py", line 271, in
Brice> ttfFontProperty sfnt = font.get_sfnt() RuntimeError: No
Brice> SFNT name table
Try editing matplotlib/font_manager.py on line 458 and replacing
prop = ttfFontProperty(font)
with
try: prop = ttfFontProperty(font)
except: continue
Let me know if this helps...
JDH
|
|
From: Brice T. <B.P...@ci...> - 2005-07-07 11:50:02
|
Thank you for your help, I tried to do as you said and I got the
following messages and then python quit: (I haven't planned to use
PyGTK as I want to use WX.)
Many Thanks
Brice
import pylab
/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py:456: UserWarning: Could not open
font file /Library/Fonts/NISC18030.ttf
warnings.warn("Could not open font file %s"%fpath)
/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py:456: UserWarning: Could not open
font file /Library/Fonts/fonts.cache-1
warnings.warn("Could not open font file %s"%fpath)
/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py:456: UserWarning: Could not open
font file /System/Library/Fonts/LastResort.dfont
warnings.warn("Could not open font file %s"%fpath)
/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/matplotlib/font_manager.py:456: UserWarning: Could not open
font file /System/Library/Fonts/Keyboard.dfont
warnings.warn("Could not open font file %s"%fpath)
No module named pygtk
PyGTK version 1.99.16 or greater is required to run the GTK Matplotlib
backends
On 6 Jul 2005, at 15:51, John Hunter wrote:
>>>>>> "Brice" == Brice Thurin <B.P...@ci...> writes:
> Brice> packages/matplotlib/font_manager.py", line 458, in
> Brice> createFontDict prop = ttfFontProperty(font) File
> Brice>
> "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
> Brice> packages/matplotlib/font_manager.py", line 271, in
> Brice> ttfFontProperty sfnt = font.get_sfnt() RuntimeError: No
> Brice> SFNT name table
>
>
> Try editing matplotlib/font_manager.py on line 458 and replacing
>
>
> prop = ttfFontProperty(font)
>
> with
>
> try: prop = ttfFontProperty(font)
> except: continue
>
> Let me know if this helps...
>
> JDH
>
>
Brice Thurin
Department of Optometry and Visual Science
City University, Northampton Square
London, EC1V 0HB, UK.
http://www.city.ac.uk/optometry/Luis/myresearch/Research/
scatteringproper.html
http://www.sharpeye.org/
Tel: +44 (0)20 7040 4157
Fax: +44(0)20 7040 8355
e-mail: B.P...@ci...
|
|
From: John H. <jdh...@ac...> - 2005-07-07 14:25:45
|
>>>>> "Brice" == Brice Thurin <B.P...@ci...> writes:
Brice> Thank you for your help, I tried to do as you said and I
Brice> got the following messages and then python quit: (I haven't
Brice> planned to use PyGTK as I want to use WX.) Many Thanks
Brice> Brice
You have to set which GUI you want to use with the backend parameter
in the matplotlibrc configuration file. Typically, people put a copy
of this in their HOME dir. If you want to use WX, I suggest setting
backend : WXAgg
in your rc file.
You can obtain a default copy of the rc file at
http://matplotlib.sf.net/.matplotlibrc or in the matplotlib src
distribution.
JDH
|