无法在我的 jupyter 笔记本上使用 !wget

rah*_*far 1 python wget python-3.x jupyter-notebook

我试图完成我的 choropleth 项目,其中涉及使用 !wget 检索 json 文件。最初,错误表明未找到多个 dll 文件。因此,我从互联网上下载了它并将其放在 wget 目录中。它解决了,但现在当我尝试运行代码来检索 json 文件时。出现应用程序错误,指出“应用程序无法正确启动 (0xc000007b)”。

我尝试重新启动电脑并重新安装 GNU。似乎没有任何作用。

#wget was unable to run

!wget --quiet https://cocl.us/sanfran_geojson -0 sf.json
Run Code Online (Sandbox Code Playgroud)

小智 5

我将代码更改为以下形式:

import wget
wget.download('https://cocl.us/sanfran_geojson', 'sf.json')
Run Code Online (Sandbox Code Playgroud)

希望这可以帮助。