cv2.imread('yan.jpg', cv2.IMREAD_GRAYSCALE)
时间: 2023-09-24 19:12:36 浏览: 104
cv2.imread('yan.jpg', cv2.IMREAD_GRAYSCALE)是一个OpenCV函数,用于以灰度模式读取图像文件'yan.jpg'。这个函数将图像文件转换为灰度图像,即每个像素的数值表示灰度级别。在这个函数中,'yan.jpg'是要读取的图像文件的路径,cv2.IMREAD_GRAYSCALE是指定读取图像的模式,表示以灰度模式读取图像。
#### 引用[.reference_title]
- *1* [树莓派 OpenCV_Python基础教程---1至10](https://blog.csdn.net/weixin_39803207/article/details/110330830)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item]
- *2* *3* [opencv-python常用函数解析及参数介绍(五)——腐蚀与膨胀](https://blog.csdn.net/DuLNode/article/details/128508966)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insertT0,239^v3^insert_chatgpt"}} ] [.reference_item]
[ .reference_list ]
阅读全文