#-*- coding:utf-8 -*-
from os import walk,path
import numpy as np
import mahotas as mh
from sklearn.cross_validation import train_test_split
from sklearn.cross_validation import cross_val_score
from sklearn.preprocessing import scale
from sklearn.decomposition import PCA
from sklearn.linear_model import LogisticRegression
from sklearn.metrics import classification_report
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
mh.imread('1.pgm')
无法在mahotas中读取PGM图像,错误信息为' RuntimeError:此格式(pgm)未知为imread'