PyCharm を使用して "SPy" Spectral Python ライブラリを試していますが、wxversion が見つからないことがわかりました。どうすれば wxversion をインストールできますか?
私は一般的にPythonに非常に慣れていないので、何か間違ったことをしていますか? これが私のコードです:
import matplotlib
#matplotlib.use('WX') #Replaced by editing matplotlibrc
from spectral import *
img = open_image('92AV3C.lan')
print img.__class__
print
print img
print
print img.shape
pixel = img[50,100]
print
print pixel.shape
band6 = img[:,:,5]
print
print band6.shape
print
arr = img.load()
print arr.__class__
print
print arr.info()
print
print arr.shape
view = imshow(img, (29, 19, 9))
これらはすべて、こちらの SPy ガイドからのものです: http://www.spectralpython.net/user_guide.html
エラーは次のとおりです。
Traceback (most recent call last):
File "/Users/pkillam/PycharmProjects/untitled/SPy Experiments", line 36, in <module>
File "/Library/Python/2.7/site-packages/spectral/graphics/spypylab.py", line 1238, in imshow
import matplotlib.pyplot as plt
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/pyplot.py", line 98, in <module>
_backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup()
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/backends/__init__.py", line 28, in pylab_setup
globals(),locals(),[backend_name],0)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/backends/backend_wxagg.py", line 6, in <module>
import backend_wx # already uses wxversion.ensureMinimal('2.8')
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/backends/backend_wx.py", line 53, in <module>
raise ImportError(missingwxversion)
ImportError: Matplotlib backend_wx and backend_wxagg require wxversion, which was not found.
また、SPy に関する他のガイドやチュートリアルはありますか?