Closed AdrienLemaire closed 7 years ago
Update. After adding the following line:
weights[0] = weights[0].reshape(list(reversed(weights[0].shape)))
after line 88, I got the error Intel MKL FATAL ERROR: Cannot load libmkl_avx2.so or libmkl_def.so.
just after start of iteration 0x0.
Might be something wrong with my conda env. Reinstalled a tensorflow + image-analogies env with virtualenv py3.6 and it seems to work now (now iteration 1x4)
Well, the resulting images look like nothing, so there must be something wrong with my installation and the code :( Support appreciated.
Input A: A': B:
Output:
Which version of Keras are you using? Sounds like you're using Keras v2 whereas this currently supports v1.
I see, maybe this could be updated in the readme. Will try again, thx!
@awentzonline there's also something wrong with the pip package. While I can see versions hardcoded with ==
in the requirements.txt file, the pip package metadata shows >=
instead, hence keras 2 gets installed instead of 1:
Requires-Dist: Keras (>=1.0.0)
Requires-Dist: Pillow (>=3.1.1)
Requires-Dist: PyYAML (>=3.11)
Requires-Dist: Theano (>=0.8.2)
Requires-Dist: h5py (>=2.5.0)
Requires-Dist: numpy (>=1.10.4)
Requires-Dist: scikit-learn (>=0.17.0)
Requires-Dist: scipy (>=0.17.0)
Requires-Dist: six (>=1.10.0)
@awentzonline after force installing the requirements.txt package versions, I'm now getting the following error:
Using TensorFlow backend.
ValueError: Not property objects (Not property objects)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/dori/Projects/personal/image-analogies/venv/bin/make_image_analogy.py", line 13, in <module>
import image_analogy.main
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/image_analogy/main.py", line 9, in <module>
from image_analogy import img_utils, vgg16
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/image_analogy/img_utils.py", line 4, in <module>
from . import vgg16
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/image_analogy/vgg16.py", line 3, in <module>
import h5py
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/h5py/__init__.py", line 31, in <module>
from .highlevel import *
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/h5py/highlevel.py", line 13, in <module>
from ._hl.base import is_hdf5, HLObject
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/h5py/_hl/base.py", line 78, in <module>
dlapl = default_lapl()
File "/home/dori/Projects/personal/image-analogies/venv/lib/python3.6/site-packages/h5py/_hl/base.py", line 65, in default_lapl
lapl = h5p.create(h5p.LINK_ACCESS)
File "h5py/_objects.pyx", line 54, in h5py._objects.with_phil.wrapper (/tmp/pip-build-a61i3wcx/h5py/h5py/_objects.c:2847)
File "h5py/_objects.pyx", line 55, in h5py._objects.with_phil.wrapper (/tmp/pip-build-a61i3wcx/h5py/h5py/_objects.c:2805)
File "h5py/h5p.pyx", line 131, in h5py.h5p.create (/tmp/pip-build-a61i3wcx/h5py/h5py/h5p.c:2886)
File "h5py/h5p.pyx", line 72, in h5py.h5p.propwrap (/tmp/pip-build-a61i3wcx/h5py/h5py/h5p.c:2693)
ValueError: Not a property list class (Not a property list class)
What version of h5py are you using ? The one I have installed is v2.5.0 :/
looking at the h5py repo, seems like the v2.5 branch was quite buggy. Installed the latest version 2.7, and it force installed numpy 1.12.1. Restarting a make_image_analogy.py run and crossing fingers...
Unfortunately, it still doesn't look anything like a city. I wasn't expecting something of high quality (purposedly ran on images scaled down to 512px to test it out with cpu on my laptop), and the plan was then to re-run the script on AWS with GPU using the HD images. But clearly, if I tried AWS now, it'd still result in some garbled image.
I didn't use any option (simply make_image_analogy.py images/a.jpg images/ap.jpg images/bp.jpg out/b
). Does that explain the result? Are options mandatory for this use-case maybe?
@Fandekasp I must've accidentally closed this without commenting.
Two things: quality settings are documented in the readme, and the mask you're using for the city should probably be more detailed if you want interesting results.
This is some random thing I made available for free a year ago and is otherwise a time sink for me. Passive-aggressive comments like yours make me less enthusiastic about supporting this at all.
@awentzonline at the time, it felt like coming to your door, explaining you an issue I had and asking for help, then... getting the door slammed to my face ^^ Sorry for the reaction, and thank you for coming back to give more details.
I'm currently finishing the fast.ai course, and will then study Keras in more detail. Since I'm very interested by this kind of project, I might even be able to upgrade your repo to the latest packages versions. Keep in touch
Hey, no big deal--I hope you end up with some nice results.
after installing Tensorflow Python 3 / CPU only on anaconda, I tried to run the script without success:
Any idea how to solve this issue ?
PS: Note that I renamed all calls
Convolution2D(XXX, 3, 3, activation=...
intoConv2D(XXX, (3, 3), activation=...
to fix the many UserWarnings