Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
def get_session():
config = tf.ConfigProto()
config.gpu_options.allow_growth = True
return tf.Session(config=config)
keras.backend.tensorflow_backend.set_session(get_session())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment