python编译报错:
SyntaxError: Non-ASCII character ‘\xe8’ in file xxx原因是不支持中文注释,如这种中英文混杂注释:
# Subtract off the mean and divide by the variance of the pixels.
#减去平均值并除以像素的方差
解决办法:
在文件第一行加上
#encoding:utf-8
python编译报错:
SyntaxError: Non-ASCII character ‘\xe8’ in file xxx原因是不支持中文注释,如这种中英文混杂注释:
# Subtract off the mean and divide by the variance of the pixels.
#减去平均值并除以像素的方差
解决办法:
在文件第一行加上
#encoding:utf-8