kevinlin311tw / CDCL-human-part-segmentation

Repository for Paper: Cross-Domain Complementary Learning Using Pose for Multi-Person Part Segmentation (TCSVT20)
https://arxiv.org/abs/1907.05193
Other
281 stars 43 forks source link

Needed to set "allow_growth" #9

Closed SiftingSands closed 3 years ago

SiftingSands commented 3 years ago

Just documenting this in case anyone else encounters this issue. Built the provided dockerfile and ran python3 inference_15parts.py --scale=1 --scale=0.5 --scale=0.75

Saw E tensorflow/stream_executor/cuda/cuda_dnn.cc:373] Could not create cudnn handle: CUDNN_STATUS_INTERNAL_ERROR (among other errors) when calling model.predict.

Resolved the issue by adding the following to inference_15parts.py

import tensorflow as tf
from keras.backend.tensorflow_backend import set_session

config = tf.ConfigProto()
config.gpu_options.allow_growth = True
sess = tf.Session(config=config)
set_session(sess)