https://qiita.com/rrryutaro/items/10142d3c3397406e5e2b
このサイトを参考にしてコードを打ったのですが、エラーが出てしまいました。どなたかわかる方がいたら教えてください。
Traceback (most recent call last):
File "hoge.py", line 10, in <module>
img1_2 = img1[162:162+14, 467:467+32]
TypeError: 'NoneType' object has no attribute '__getitem__'
今度は別のエラーが出てしまいました。
/Users/xxxxx/Library/Python/2.7/lib/python/site-packages/numpy/core/fromnumeric.py:3118: RuntimeWarning: Mean of empty slice. out=out, **kwargs)
/Users/xxxxx/Library/Python/2.7/lib/python/site-packages/numpy/core/_methods.py:85: RuntimeWarning: invalid value encountered in double_scalars ret = ret.dtype.type(ret / rcount) nan nan
/Users/xxxxx/Library/Python/2.7/lib/python/site-packages/numpy/core/fromnumeric.py:3118: RuntimeWarning: Mean of empty slice. out=out, **kwargs) /Users/xxxxx/Library/Python/2.7/lib/python/site-packages/numpy/core/_methods.py:85: RuntimeWarning: invalid value encountered in double_scalars ret = ret.dtype.type(ret / rcount) nan nan