当前位置:网站首页>Solve importerror: cannot import name 'imread' from 'SciPy misc‘
Solve importerror: cannot import name 'imread' from 'SciPy misc‘
2022-04-23 20:47:00 【NuerNuer】
Official explanation : scipy.misc.imread ( scipy.misc.imsave) is deprecated in SciPy 1.0.0, and will be removed in 1.2.0.
So the version is higher than 1.2.0 Of scipy It will report an error that the function cannot find , There are two solutions .
1. The official advice :
Use ``imageio.imwrite`` instead.
Use ``imageio.imread`` instead.
In the code import imageio, then
import imageio
imageio.imwrite('a.png', res)
b = imageio.imread('b.png')
2. to scipy Downgrade
pip install pillow==5.2.0
pip install scipy==1.1.0
# or pip install scipy==1.0.0
I remember here pillow Also downgraded .
版权声明
本文为[NuerNuer]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204210545522944.html
边栏推荐
- Unity animation creates sequence frame code and generates animationclip
- Thinking after learning to type
- Unity ECS dots notes
- Parsing methods of JSON data in C - jar and jobobject: error reading jar from jsonreader Current JsonReader item
- Latex formula
- How many hacking methods do you know?
- 笔记本电脑卡顿怎么办?教你一键重装系统让电脑“复活”
- LeetCode-279-完全平方数
- Leetcode 1337. Row K with the weakest combat effectiveness in the matrix
- High paid programmer & interview question series 91 limit 20000 loading is very slow. How to solve it? How to locate slow SQL?
猜你喜欢
JS arrow function user and processing method of converting arrow function into ordinary function
[SQL] string series 2: split a string into multiple lines according to specific characters
浅谈数据库设计之三大范式
Gsi-ecm digital platform for engineering construction management
Preliminary understanding of cache elimination algorithm (LRU and LFU)
Mysql database common sense storage engine
Addition, deletion, modification and query of MySQL advanced table
Summary and effect analysis of methods for calculating binocular parallax
Unity solves Z-fighting
一些接地气的话儿
随机推荐
2021-09-02 unity project uses rider to build hot change project failure record of ilruntime
IOT 设计与开发
[SQL] string series 2: split a string into multiple lines according to specific characters
Leetcode 709, convert to lowercase
Sequential state
ros功能包内自定义消息引用失败
3-5通过XSS获取cookie以及XSS后台管理系统的使用
Unity Odin ProgressBar add value column
Go zero framework database avoidance Guide
Leetcode-279-complete square number
SQL: query duplicate data and delete duplicate data
The construction and use of Fortress machine and springboard machine jumpserver are detailed in pictures and texts
The iswow64process function determines the number of program bits
MySQL进阶之数据的增删改查(DML)
Go limit depth traversal of files in directory
Psychological formula for converting RGB to gray value
mmap、munmap
Addition, deletion, modification and query of MySQL advanced table
Addition, deletion, modification and query of advanced MySQL data (DML)
go reflect