如何升级Python Pandas版本?
我在Jupyter笔记本中使用Python。我的熊猫版本
pandas: 0.23.4
无法使用爆炸或其他高级功能。我正在尝试使用类似的代码来升级它:
!pip install -- upgrade pandas
但是继续接收错误消息,例如:
无法获取url https://pypi.org/simple/simple/ipytle/ipython/ 那里:是一个 确认SSL证书的问题: httpsconnectionpool(host ='pypi.org',端口= 443):最大检索超过 使用url:/simple/ipython/(由 sslerror(sslcertverificationerror(1,'[ssl:centerrify_failed] 证书验证失败:无法获得本地发行人证书 (_SSL.C:1045)'))) - 跳过
有人知道如何重写代码吗?
I am using Python in Jupyter Notebook. My Pandas version is
pandas: 0.23.4
in which I cannot use Explode or other advanced functions. I am trying to upgrade it using the codes like:
!pip install -- upgrade pandas
But keep receiving error messages like:
Could not fetch URL https://pypi.org/simple/ipython/: There was a
problem confirming the ssl certificate:
HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded
with url: /simple/ipython/ (Caused by
SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED]
certificate verify failed: unable to get local issuer certificate
(_ssl.c:1045)'))) - skipping
Does anyone know how to rewrite the codes?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
它可能提供临时解决方案。我认为有一个限制与pypi.org的连接的代理或防火墙规则;
It might provide a temporary solution. I think there is a proxy or firewall rule restricting connection to pypi.org;
我想您需要提供有关设置的更多信息,例如您使用什么操作系统。呼叫
!PIP安装 - 升级pandas
执行shell命令。例如,如果您使用Ubuntu,则此命令将尝试使用System Package Manager安装PANDAS包,并且由于您需要Sudo特权而失败。似乎您尝试在本地执行为云协作平台开发的代码(例如Google COLAB)。不幸的是,您需要仔细这样做。
我建议您为您的项目创建一个单独的虚拟环境,并在此处安装依赖项。例如,我使用诗歌来管理项目中的依赖项,但您也可以使用其他诗歌(Virtualenv,Anaconda,Pipenv等)。
I guess you need to provide more information about your setup, e.g., what operating system do you use. The call
!pip install --upgrade pandas
executes shell command. If, for instance, you use Ubuntu, then this command will try to install the pandas package using system package manager, and it will fail because you need sudo privileges.It seems that you try to execute locally the code developed for the cloud collaborative platforms (e.g., Google Colab). Unfortunately, you need to do this carefully.
I would recommend to you to create a separate virtual environment for your project and install dependencies there. For instance, I use poetry to manage the dependencies in my projects but you can also use others (virtualenv, anaconda, pipenv, etc.).