Error when running tensorflow in virtualenv: module 'tensorflow' has no attribute 'truncated_normal'
Keras 2.2.4 does not support TensorFlow 2.0 (it was released much before TF 2.0), so you can either downgrade TensorFlow to version 1.x, or upgrade Keras to version 2.3, which does support TensorFlow 2.0.
I have the following error when running a CNN made in keras

File
  "venv/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py",
  line 4185, in truncated_normal
      return tf.truncated_normal(shape, mean, stddev, dtype=dtype, seed=seed) AttributeError: module 'tensorflow' has no attribute
  'truncated_normal'

I have already installed and reinstalled Tensorflow 2.0 several times. What could be happening?