ajbrock / Neural-Photo-Editor

A simple interface for editing natural photos with generative neural networks.
MIT License
2.08k stars 197 forks source link

Numpy fails to interpret IAN_Simple.npz? #11

Closed graynk closed 7 years ago

graynk commented 7 years ago

Hi, I finally managed to install cuda and dev versions of lasagne and theano. Now when I try to launch NPE I get this:

gray@gray-linux:~/Neural-Photo-Editor$ python NPE.py Using gpu device 0: GeForce GTX 970 (CNMeM is disabled, cuDNN 5105) Loading weights Traceback (most recent call last): File "NPE.py", line 53, in model = IAN(config_path = 'IAN_simple.py', dnn = True) File "/home/gray/Neural-Photo-Editor/API.py", line 30, in init GANcheckpoints.load_weights(self.weights_fname,params) File "/home/gray/Neural-Photo-Editor/GANcheckpoints.py", line 39, in load_weights param_dict = np.load(fname) File "/home/gray/miniconda2/lib/python2.7/site-packages/numpy/lib/npyio.py", line 416, in load "Failed to interpret file %s as a pickle" % repr(file)) IOError: Failed to interpret file 'IAN_simple.npz' as a pickle

Am I doing something wrong? As far as I can understand from search results, np.load is used for binary .npz files, but all I can see in IAN_Simple.npz are three strings of text:

version https://git-lfs.github.com/spec/v1 oid sha256:82e5fd3ff68b2c9095935c9db269e086e2dd27704b629853e1f03473e7059bd7 size 205207893

UPD: Whoops, my bad. For some reason git clone didn't download raw .npz files. I downloaded them manually and now everything works

ajbrock commented 7 years ago

Glad I could help! =p I'm guessing it has to do with the fact that I uploaded them using git-lfs, which may or may not be a requirement for downloading them? Not entirely sure.