lengstrom / fast-style-transfer

TensorFlow CNN for fast style transfer ⚡🖥🎨🖼
10.91k stars 2.6k forks source link

Could not create cudnn handle: CUDNN_STATUS_INTERNAL_ERROR #263

Open LEEWARDCODER opened 3 years ago

LEEWARDCODER commented 3 years ago

hi, when I get the env ready and type in the script python evaluate.py --checkpoint C:\Users\hasee\fast-style-transfer\examples\style\la_muse.ckpt --in-path C:\Users\hasee\fast-style-transfer\examples\content\chicago.jpg --out-path C:\Users\hasee\fast-style-transfer\examples\result\chicago.jpg, it thorws some errors.

**WARNING:tensorflow:From F:\anaconda\envs\tf-gpu\lib\site-packages\tensorflow_core\python\ops\resource_variable_ops.py:1635: calling BaseResourceVariable.__init__ (from tensorflow.python.ops.resource_variable_ops) with constraint is deprecated and will be removed in a future version.
Instructions for updating:**

2021-02-24 09:29:24.097223: E tensorflow/stream_executor/cuda/cuda_dnn.cc:329] **Could not create cudnn handle:** CUDNN_STATUS_INTERNAL_ERROR

  (0) Unknown: **Failed to get convolution algorithm. This is probably because cuDNN failed to initialize, so try looking to see if a warning log message was printed above.**
         [[{{node Conv2D}}]]
         [[add_37/_99]]

**Errors may have originated from an input operation.**

I have no idea where is wrong, and how to fix

LEEWARDCODER commented 3 years ago

image image

LEEWARDCODER commented 3 years ago

python evaluate.py --checkpoint C:\Users\hasee\fast-style-transfer\examples\style\la_muse.ckpt --in-path C:\Users\hasee\fast-style-transfer\examples\content\chicago.jpg --out-path C:\Users\hasee\fast-style-transfer\examples\results\chicago.jpg

LEEWARDCODER commented 3 years ago

above line is the input script

impactcolor commented 2 years ago

@tandage any progress on this?

noahebrown commented 2 years ago

For anyone else with this issue this solved it for me Add tf.compat.v1.disable_v2_behavior() before the tensorflow GPU session creation in optimize.py