i built a model to do multiclass semantic segmentation, already trained. But now i want to predict all images patches in my TEST DB thats already loaded and save the output prediction patch to put back together as a full image later...
im using this code below, it runs but doesnt save the output predicted image... the indicator changes lines when runnin' but i got nothing on the output... can someone help me? sorry about my bad english
img_number = 1
for image in range(test_images.shape[0]):
input_img = [test_images] #(test_images) e [test_images]roda mais nao salva
y_pred = model.predict(input_img)
y_pred_argmax=np.argmax(y_pred, axis=3)
prediction = y_pred_argmax[image]
cv2.imwrite('/content/drive/MyDrive/BD_filtred/ok'+str(img_number)+".png", prediction) #prediciton
img_number +=1