Import “tensorflow.keras.preprocessing.image” could not be resolved
This is the code block in colab
grader-required-cell
import os
import zipfile
import random
import shutil
import tensorflow as tf
from tensorflow.keras.preprocessing.image import ImageDataGenerator
from shutil import copyfile
import matplotlib.pyplot as plt
Also note that you filed this under DLS Course 4, but I don’t recognize that code as being from any of the DLS C4 assignments. Is this a course assignment in some other course or some personal project that you are working on?
Also note that you mention “colab”. That is not used anywhere in DLS. Maybe in some of the other specializations here, but not DLS. If you are running in Colab, note that the versions of all the packages you get will be different (more up-to-date) than the TensorFlow and other packages used in any of the courses here. The APIs are not guaranteed to be forward compatible if you take a notebook from some course here and try to run it with the very latest and greatest of all the various packages.
Hey,
Thank u for your help
I’m follow the assignment labs on the course. I’m on course two week 1. Hope I haven’t posted it in the wrong forum.
Someone has mention it could be because of a depreciation of an API
Yes, that is not from DLS course 2. I’m very familiar with DLS C2 and do not recognize that assignment. Are you sure it’s not from one of the TensorFlow specializations?
As this is not a DLS query, please move this to the relevant course category, so, official mentors for that course can guide you. Check this on how to do this.
BTW, this category is Deep Learning Specialization → Convolutional Neural Networks.
You are taking TensorFlow Developer Professional Certificate → Convolutional Neural Networks in TensorFlow.