〇、前情提要
在b站跟着up主 天理难容hhhhh 学用keras分类mnist数据集,在第一步认识mnist数据集时,出现了encode_chunked=req.has_header('Transfer-encoding'))
报错。
参考:
- 手把手用keras分类mnist数据集
https://blog.csdn.net/qq_40438165/article/details/105846692 - 手把手完成mnist手写数字识别
https://www.bilibili.com/video/BV16g4y1z7Qu?t=1536
一、问题描述
Downloading data from https://storage.googleapis.com/tensorflow/tf-keras-datasets/mnist.npz
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1317, in do_open
encode_chunked=req.has_header('Transfer-encoding'))
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1229, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1275, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7