input: Write a function to create and train a machine learning model using Keras that distinguishes between cats and dogs, given a dataset of 800 images. The function should compile the model with a binary cross-entropy loss, 'adam' optimizer, and 'accuracy' as the metric. The model should be trained for 5 epochs using an ImageDataGenerator for data augmentation and preprocessing.
  
  assert create_cat_dog_model() == None
  assert create_cat_dog_model() == None
  assert create_cat_dog_model() == None
  assert create_cat_dog_model() == None
output: def create_cat_dog_model():
      from tensorflow.keras.models import Sequential
      from tensorflow.keras.layers import Conv2D, MaxPooling2D, Flatten, Dense
      from tensorflow.keras.preprocessing.image import ImageDataGenerator
  
      model = Sequential([
          Conv2D(32, (3, 3), activation='relu', input_shape=(150, 150, 3)),
          MaxPooling2D(2, 2),
          Conv2D(64, (3, 3), activation='relu'),
          MaxPooling2D(2, 2),
          Conv2D(128, (3, 3), activation='relu'),
          MaxPooling2D(2, 2),
          Flatten(),
          Dense(512, activation='relu'),
          Dense(1, activation='sigmoid')
      ])
  
      model.compile(loss='binary_crossentropy', optimizer='adam', metrics=['accuracy'])
  
      train_datagen = ImageDataGenerator(rescale=1./255, shear_range=0.2, zoom_range=0.2, horizontal_flip=True)
      train_generator = train_datagen.flow_from_directory('dataset/train', target_size=(150, 150), batch_size=32, class_mode='binary')
  
      model.fit(train_generator, epochs=5)