i want to read my mask to use them as an input for my training process my masks are located in a folder named mask (the shape of my images (128,128,4)) I used this code
path_folder = "" # the path to the folder containing masks
mask_path= path_folder + '/masks/'
mask_file = os.listdir(mask_path)
y_train = np.zeros((len(mask_file), 128, 128, 1), dtype=np.bool)# this is the nump array where Iwant to put my masks
ctr =0
for n, id_ in tqdm(enumerate(mask_file), total=len(mask_file)):
mask = imread(mask_path + mask_file[n])
y_train[ctr] = mask
ctr = ctr +1
I got this error ValueError: could not broadcast input array from shape (128,128,4) into shape (128,128,1) Have you any idea what should I do