-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'map' object is not subscriptable #1
Comments
Thank you for using my discoGAN code and your question. I think above error, (-) lines = map(lambda line: line.strip(), lines)
(+) lines = [line.strip() for line in lines] Let me know if you have another problem. |
Thank you =) On to the next problem: |
This error is also caused by (-) items = map(lambda line: line.split(), lines)
(+) items = [line.split() for line in lines] Enjoy the code! |
oh I didn't see that XD fixed it and all the other parts where map() could be a problem, but now I'm getting:
It seems like your project is just not compatible with my python and package versions |
I followed all your instructions, but when trying to train, I get this output:
./train.sh The mode is train. complete initializing model. A2B/Generator/conv1/weights:0 A2B/Generator/conv2/weights:0 A2B/Generator/conv2/batch_norm/beta:0 A2B/Generator/conv3/weights:0 A2B/Generator/conv3/batch_norm/beta:0 A2B/Generator/conv4/weights:0 A2B/Generator/conv4/batch_norm/beta:0 A2B/Generator/convt2/weights:0 A2B/Generator/convt2/batch_norm/beta:0 A2B/Generator/convt3/weights:0 A2B/Generator/convt3/batch_norm/beta:0 A2B/Generator/convt4/weights:0 A2B/Generator/convt4/batch_norm/beta:0 A2B/Generator/convt5/weights:0 B2A/Generator/conv1/weights:0 B2A/Generator/conv2/weights:0 B2A/Generator/conv2/batch_norm/beta:0 B2A/Generator/conv3/weights:0 B2A/Generator/conv3/batch_norm/beta:0 B2A/Generator/conv4/weights:0 B2A/Generator/conv4/batch_norm/beta:0 B2A/Generator/convt2/weights:0 B2A/Generator/convt2/batch_norm/beta:0 B2A/Generator/convt3/weights:0 B2A/Generator/convt3/batch_norm/beta:0 B2A/Generator/convt4/weights:0 B2A/Generator/convt4/batch_norm/beta:0 B2A/Generator/convt5/weights:0 A/Discriminator/conv1/weights:0 A/Discriminator/conv2/weights:0 A/Discriminator/conv2/batch_norm/beta:0 A/Discriminator/conv3/weights:0 A/Discriminator/conv3/batch_norm/beta:0 A/Discriminator/conv4/weights:0 A/Discriminator/conv4/batch_norm/beta:0 A/Discriminator/conv5/weights:0 B/Discriminator/conv1/weights:0 B/Discriminator/conv2/weights:0 B/Discriminator/conv2/batch_norm/beta:0 B/Discriminator/conv3/weights:0 B/Discriminator/conv3/batch_norm/beta:0 B/Discriminator/conv4/weights:0 B/Discriminator/conv4/batch_norm/beta:0 B/Discriminator/conv5/weights:0 complete model build. 2017-07-16 20:31:36.540850: 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-07-16 20:31:36.540880: 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-07-16 20:31:36.540890: 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-07-16 20:31:36.540899: 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. Traceback (most recent call last): File "train.py", line 236, in <module> tf.app.run() File "/Users/me/miniconda3/envs/face-extract/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 48, in run _sys.exit(main(_sys.argv[:1] + flags_passthrough)) File "train.py", line 193, in main data_A, data_B = data.get_data() File "/Users/me/Documents/python/discoGAN.tensorflow.slim-master/data.py", line 76, in get_data n_test=FLAGS.n_test) File "/Users/me/Documents/python/discoGAN.tensorflow.slim-master/data.py", line 40, in _get_celebA_files image_data = _read_attr_file( attr_file, image_dir ) File "/Users/me/Documents/python/discoGAN.tensorflow.slim-master/data.py", line 27, in _read_attr_file columns = ['image_path'] + lines[1].split() TypeError: 'map' object is not subscriptable
The text was updated successfully, but these errors were encountered: