infocusp / tf_cnnvis

CNN visualization tool in TensorFlow
MIT License
781 stars 208 forks source link

installation platform #41

Closed xuxiaoqing2016 closed 6 years ago

xuxiaoqing2016 commented 6 years ago

Hello, Which installation platform is suit for,Linus or Windows? Thank you.

falaktheoptimist commented 6 years ago

Linux is preferred although windows should work too.

xuxiaoqing2016 commented 6 years ago

Hello, Thank you for your reply. I also have another problem. According to your code of Example 2, I write a program. However,I have a trouble as follows. Would you make a spare time help me solve the question? Thank you.

Generation 200: Loss = 0.04414 --- Train Accuracy = 100.00%. --- Test Accuracy = 96.97%. INFO:tensorflow:Restoring parameters from model\tmp-model Traceback (most recent call last):

File "", line 1, in runfile('E:/.spyder-py3/tf_cnnvis-master/CNN_STAP/cnn_MTI_20180322_noise_jammer.py', wdir='E:/.spyder-py3/tf_cnnvis-master/CNN_STAP')

File "C:\Program Files\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line 710, in runfile execfile(filename, namespace)

File "C:\Program Files\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line 101, in execfile exec(compile(f.read(), filename, 'exec'), namespace)

File "E:/.spyder-py3/tf_cnnvis-master/CNN_STAP/cnn_MTI_20180322_noise_jammer.py", line 335, in path_outdir="E:/5")

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\tf_cnnvis.py", line 410, in deconv_visualization path_logdir = path_logdir, path_outdir = path_outdir)

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\tf_cnnvis.py", line 169, in _get_visualization is_success = _visualization_by_layer_type(g, value_feed_dict, input_tensor, layer_type, method, path_logdir, path_outdir)

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\tf_cnnvis.py", line 227, in _visualization_by_layer_type is_success = _visualization_by_layer_name(graph, value_feed_dict, input_tensor, layer, method, path_logdir, path_outdir)

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\tf_cnnvis.py", line 303, in _visualization_by_layer_name is_success = write_results(results, layer_name, path_outdir, path_logdir, method = method)

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\utils.py", line 224, in write_results is_success = _write_deconv(results, layer, path_outdir, path_logdir)

File "C:\Program Files\Anaconda3\lib\site-packages\tf_cnnvis-1.0.0-py3.5.egg\tf_cnnvis\utils.py", line 149, in _write_deconv imsave(os.path.join(grid_image_path, "grid_image.png"), grid_images[i][0], format = "png")

File "C:\Program Files\Anaconda3\lib\site-packages\scipy\misc\pilutil.py", line 195, in imsave im = toimage(arr, channel_axis=2)

File "C:\Program Files\Anaconda3\lib\site-packages\scipy\misc\pilutil.py", line 287, in toimage raise ValueError("'arr' does not have a suitable array shape for "

ValueError: 'arr' does not have a suitable array shape for any mode.