🔄Update: [Lab-1] imread 图片读取
This commit is contained in:
@@ -1 +1,2 @@
|
||||
.idea
|
||||
*/img
|
||||
@@ -0,0 +1,11 @@
|
||||
import cv2
|
||||
import numpy as np
|
||||
|
||||
def imread(img_path):
|
||||
inner_img = cv2.imread(img_path)
|
||||
if inner_img is None:
|
||||
raise FileNotFoundError("Check your inner_img")
|
||||
return inner_img
|
||||
|
||||
if __name__ == '__main__':
|
||||
img = imread('../img/1.jpeg')
|
||||
Reference in New Issue
Block a user