DCGAN-tensorflow
DCGAN-tensorflow copied to clipboard
Failed to find a checkpoint / Raise exception!
Hi,
When I try to test my code after I trained it. I get an error. Though I have a folder with checkpoint and including folders with checkpoint files etc..
It still says failed to find a checkpoint...
I think that's what's giving the error below?
[*] Failed to find a checkpoint
Traceback (most recent call last):
File "main.py", line 97, in <module>
tf.app.run()
File "/home/quinten/anaconda2/envs/carpedm20/lib/python3.5/site-packages/tensorflow/python/platform/app.py", line 48, in run
_sys.exit(main(_sys.argv[:1] + flags_passthrough))
File "main.py", line 83, in main
raise Exception("[!] Train a model first, then run test mode")
Exception: [!] Train a model first, then run test mode
Full code below.
python main.py --dataset=fordcgan_2 --input_height=306 --checkpoint_dir=checkpoint/fortfdcgan_64_108_108/ --visualize=True
{'batch_size': 64,
'beta1': 0.5,
'checkpoint_dir': 'checkpoint/fortfdcgan_64_108_108/',
'crop': False,
'dataset': 'fordcgan_2',
'epoch': 50,
'input_fname_pattern': '*.jpg',
'input_height': 306,
'input_width': None,
'learning_rate': 0.0002,
'output_height': 306,
'output_width': None,
'sample_dir': 'samples2',
'train': False,
'train_size': inf,
'visualize': True}
2017-11-30 00:20:58.812956: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-30 00:20:58.812972: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-30 00:20:58.812977: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
2017-11-30 00:20:58.812980: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-30 00:20:58.812983: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use FMA instructions, but these are available on your machine and could speed up CPU computations.
---------
Variables: name (type shape) [size]
---------
generator/g_h0_lin/Matrix:0 (float32_ref 100x204800) [20480000, bytes: 81920000]
generator/g_h0_lin/bias:0 (float32_ref 204800) [204800, bytes: 819200]
generator/g_bn0/beta:0 (float32_ref 512) [512, bytes: 2048]
generator/g_bn0/gamma:0 (float32_ref 512) [512, bytes: 2048]
generator/g_h1/w:0 (float32_ref 5x5x256x512) [3276800, bytes: 13107200]
generator/g_h1/biases:0 (float32_ref 256) [256, bytes: 1024]
generator/g_bn1/beta:0 (float32_ref 256) [256, bytes: 1024]
generator/g_bn1/gamma:0 (float32_ref 256) [256, bytes: 1024]
generator/g_h2/w:0 (float32_ref 5x5x128x256) [819200, bytes: 3276800]
generator/g_h2/biases:0 (float32_ref 128) [128, bytes: 512]
generator/g_bn2/beta:0 (float32_ref 128) [128, bytes: 512]
generator/g_bn2/gamma:0 (float32_ref 128) [128, bytes: 512]
generator/g_h3/w:0 (float32_ref 5x5x64x128) [204800, bytes: 819200]
generator/g_h3/biases:0 (float32_ref 64) [64, bytes: 256]
generator/g_bn3/beta:0 (float32_ref 64) [64, bytes: 256]
generator/g_bn3/gamma:0 (float32_ref 64) [64, bytes: 256]
generator/g_h4/w:0 (float32_ref 5x5x3x64) [4800, bytes: 19200]
generator/g_h4/biases:0 (float32_ref 3) [3, bytes: 12]
discriminator/d_h0_conv/w:0 (float32_ref 5x5x3x64) [4800, bytes: 19200]
discriminator/d_h0_conv/biases:0 (float32_ref 64) [64, bytes: 256]
discriminator/d_h1_conv/w:0 (float32_ref 5x5x64x128) [204800, bytes: 819200]
discriminator/d_h1_conv/biases:0 (float32_ref 128) [128, bytes: 512]
discriminator/d_bn1/beta:0 (float32_ref 128) [128, bytes: 512]
discriminator/d_bn1/gamma:0 (float32_ref 128) [128, bytes: 512]
discriminator/d_h2_conv/w:0 (float32_ref 5x5x128x256) [819200, bytes: 3276800]
discriminator/d_h2_conv/biases:0 (float32_ref 256) [256, bytes: 1024]
discriminator/d_bn2/beta:0 (float32_ref 256) [256, bytes: 1024]
discriminator/d_bn2/gamma:0 (float32_ref 256) [256, bytes: 1024]
discriminator/d_h3_conv/w:0 (float32_ref 5x5x256x512) [3276800, bytes: 13107200]
discriminator/d_h3_conv/biases:0 (float32_ref 512) [512, bytes: 2048]
discriminator/d_bn3/beta:0 (float32_ref 512) [512, bytes: 2048]
discriminator/d_bn3/gamma:0 (float32_ref 512) [512, bytes: 2048]
discriminator/d_h4_lin/Matrix:0 (float32_ref 204800x1) [204800, bytes: 819200]
discriminator/d_h4_lin/bias:0 (float32_ref 1) [1, bytes: 4]
Total size of variables: 29505924
Total bytes of variables: 118023696
[*] Reading checkpoints...
[*] Failed to find a checkpoint
Traceback (most recent call last):
File "main.py", line 97, in <module>
tf.app.run()
File "/home/quinten/anaconda2/envs/carpedm20/lib/python3.5/site-packages/tensorflow/python/platform/app.py", line 48, in run
_sys.exit(main(_sys.argv[:1] + flags_passthrough))
File "main.py", line 83, in main
raise Exception("[!] Train a model first, then run test mode")
Exception: [!] Train a model first, then run test mode
have you solved this?i have the same error
yes, I am getting the same error. Can anybody help?
Same error for me, have anyone solved this?
i really understand a way details checkpoint & why it neccessary.
same here
Any solution to this??? I am also getting the same error.
Getting the same error