Skip to content
This repository has been archived by the owner on Apr 23, 2021. It is now read-only.

Plot option broke #4

Open
ngonthier opened this issue Jun 21, 2017 · 1 comment
Open

Plot option broke #4

ngonthier opened this issue Jun 21, 2017 · 1 comment
Labels

Comments

@ngonthier
Copy link
Owner

After updating Tensorfow to 1.2, I get an error when to use --plot option.
python Style_Transfer.py --verbose --loss nmoments --n 4 --plot verbosity turned on style BrickSmallBrown0293_1_S content BrickSmallBrown0293_1_S Plot Content Image Plot Style Image Namespace(clip_var=1, content_img_name='BrickSmallBrown0293_1_S', content_strengh=0.001, data_folder='data/', gpu_frac=0.0, img_ext='.png', img_folder='images/', init_noise_ratio=1.0, learning_rate=10, loss=['nmoments'], max_iter=2000, maxcor=10, n=4, optimizer='lbfgs', output_img_name='Pastiche', p=4, plot=True, pooling_type='avg', print_iter=200, sampling='up', start_from_noise=1, style_img_name='BrickSmallBrown0293_1_S', tf_profiler=False, tv=False, type_of_loss='add', verbose=True) Load Data data/gram_BrickSmallBrown0293_1_S_248_265_avg_SAME.pkl net loaded and gram computation after 5.273186683654785 s Memory Growth 2017-06-21 16:11:54.687115: 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-06-21 16:11:54.687149: 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-06-21 16:11:54.807623: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:893] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero 2017-06-21 16:11:54.807972: I tensorflow/core/common_runtime/gpu/gpu_device.cc:940] Found device 0 with properties: name: GeForce GTX 680 major: 3 minor: 0 memoryClockRate (GHz) 1.0845 pciBusID 0000:03:00.0 Total memory: 1,95GiB Free memory: 1,54GiB 2017-06-21 16:11:54.808000: I tensorflow/core/common_runtime/gpu/gpu_device.cc:961] DMA: 0 2017-06-21 16:11:54.808011: I tensorflow/core/common_runtime/gpu/gpu_device.cc:971] 0: Y 2017-06-21 16:11:54.808025: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1030] Creating TensorFlow device (/gpu:0) -> (device: 0, name: GeForce GTX 680, pci bus id: 0000:03:00.0) Noisy image generation init_noise_ratio = 1.0 Plot Initial Image init loss total Start LBFGS optim with a print each 200 iterations Error, in the lbfgs case the image can be strange and incorrect Close Sess Computation total for 17.994908332824707 s Traceback (most recent call last): File "Style_Transfer.py", line 1472, in <module> main_with_option() File "Style_Transfer.py", line 1469, in main_with_option style_transfer(args,pooling_type,padding) File "Style_Transfer.py", line 1388, in style_transfer optimizer = tf.contrib.opt.ScipyOptimizerInterface(loss_total,bounds=bnds, File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/python/util/lazy_loader.py", line 53, in __getattr__ module = self._load() File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/python/util/lazy_loader.py", line 42, in _load module = importlib.import_module(self.__name__) File "/home/nicolas/anaconda3/lib/python3.6/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 978, in _gcd_import File "<frozen importlib._bootstrap>", line 961, in _find_and_load File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 655, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 678, in exec_module File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/contrib/__init__.py", line 35, in <module> from tensorflow.contrib import image File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/contrib/image/__init__.py", line 40, in <module> from tensorflow.contrib.image.python.ops.single_image_random_dot_stereograms import single_image_random_dot_stereograms File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/contrib/image/python/ops/single_image_random_dot_stereograms.py", line 26, in <module> "_single_image_random_dot_stereograms.so")) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/contrib/util/loader.py", line 55, in load_op_library ret = load_library.load_op_library(path) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/load_library.py", line 84, in load_op_library exec(wrappers, module.__dict__) File "<string>", line 248, in <module> File "<string>", line 114, in _InitOpDefLibrary File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 481, in Merge descriptor_pool=descriptor_pool) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 535, in MergeLines return parser.MergeLines(lines, message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 568, in MergeLines self._ParseOrMerge(lines, message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 583, in _ParseOrMerge self._MergeField(tokenizer, message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 684, in _MergeField merger(tokenizer, message, field) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 773, in _MergeMessageField self._MergeField(tokenizer, sub_message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 684, in _MergeField merger(tokenizer, message, field) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 773, in _MergeMessageField self._MergeField(tokenizer, sub_message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 684, in _MergeField merger(tokenizer, message, field) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 773, in _MergeMessageField self._MergeField(tokenizer, sub_message) File "/home/nicolas/anaconda3/lib/python3.6/site-packages/google/protobuf/text_format.py", line 652, in _MergeField (message_descriptor.full_name, name)) google.protobuf.text_format.ParseError: 48:12 : Message type "tensorflow.AttrValue" has no field named "5"

@ngonthier ngonthier added the bug label Jun 21, 2017
@ngonthier
Copy link
Owner Author

You need to run python with the prefixe argument :LANG=en_US

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant