少し検索しましたが、PyPyでPILを使用するためのチュートリアルが見つかりませんでした。PyPyのブログによると、PILがサポートされています。
- PYTHONPATHにpipを使用してPILをインストールしました。
- ダウンロード後、pipは2つの.pydファイル(_imaging.pydと_imagingmath.pyd)を作成します。
- インストール後、%PYTHONPATH%/ lib / site-packages/PILをPyPysite-packagesディレクトリにコピーしました。
- スクリプト(PILを使用)を実行すると、_imagingCモジュールをインポートできないと表示されます。
どうすればいいですか?
編集:私はこれをWindows 7 x64(python 2.7.1 32ビット)で実行します
これがトレースバックです(pypy 1.4.1 Windowsバイナリ):
Traceback (most recent call last):
File "app_main.py", line 53, in run_toplevel
File "tools\python\gen_images.py", line 52, in <module>
main()
File "tools\python\gen_images.py", line 44, in main
image = Image.open(file)
File "d:\pypy\site-packages\PIL\Image.py", line 1965, in open
return factory(fp, filename)
File "d:\pypy\site-packages\PIL\ImageFile.py", line 91, in __init__
self._open()
File "d:\pypy\site-packages\PIL\GifImagePlugin.py", line 97, in _open
self.seek(0) # get ready to read first frame
File "d:\pypy\site-packages\PIL\GifImagePlugin.py", line 152, in seek
self.dispose = Image.core.fill("P", self.size,
File "d:\pypy\site-packages\PIL\Image.py", line 37, in __getattr__
raise ImportError("The _imaging C module is not installed")
ImportError: The _imaging C module is not installed