关于jupyter的一些小笔记

关于jupyter的一些小笔记

1.Jupyter Notebook:单/多行注释,组合键:选中代码,按Ctrl + /。

2.安装PHATE包

使用pip直接进行安装

复制代码
pip install --user phate

成功解决AttributeError: module 'numpy' has no attribute 'float'.

报错:

复制代码
AttributeError: module 'numpy' has no attribute 'float'.
`np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
    https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations

解决方案一:

不用改代码,重新安装numpy就可以

出现这个问题的原因:np.float从1.24起被删除。所用的代码是依赖于旧版本的Numpy。可以将Numpy版本降级到1.23.5.

复制代码
conda install numpy==1.23.5
相关推荐
小趴蔡ha17 小时前
02 Anaconda、Python 与机器学习开发环境入门
python·机器学习·anaconda
2401_8685347817 小时前
RTOS之RT-Thread & Linux:线程/进程管理与调度核心差异分析
c++·python
数字化转型分享点滴18 小时前
富士康、蓝思科技为何选择四化信息?MES制造执行系统的实践
python·科技
wling030118 小时前
vasp虚频计算-python脚本
开发语言·windows·python·vasp计算
魔镜前的帅比18 小时前
(开源项目)x-claw(总)
python·ai·rust·开源
xrandzj19 小时前
Python面向对象编程入门:类、实例、初始化与封装实践
开发语言·python
matlabgoodboy1 天前
计算机毕设代做|Java Python Matlab APP 全套开发设计
java·python·课程设计
用户8356290780511 天前
Python Word 转 PDF 和 PDF 转 Word 指南
后端·python
用户8356290780511 天前
如何使用 Python 加密和保护 Word 文档
后端·python
Fluxproxy1 天前
AI数据集采集、批量模型推理报错频发?AI项目网络稳定性优化实战
python·ai·ai编程