Skip to content
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

Problem training on YaleFaces #6

Closed
kaihuchen opened this issue Oct 23, 2016 · 1 comment
Closed

Problem training on YaleFaces #6

kaihuchen opened this issue Oct 23, 2016 · 1 comment

Comments

@kaihuchen
Copy link

First I want to thank you for publishing your code!

Since RaFD is not open, and that it seems your code supports the Yale Face database (http://vismod.media.mit.edu/vismod/classes/mas622-00/datasets/), I chose to give the Yale Face db a try instead. However the program immediately exited on the following error:

(ph3) kaihuchen01@instance-6:~/mybk/tests/deconvfaces$ python faces.py train YALEfaces/yalefaces
Using Theano backend.
Found 0 instances with 0 identities
(5, 4)
height: 5 width: 4
Built model with:
Deconv layers: 5
Output shape: (320, 256, 3)
Loading data...
0it [00:00, ?it/s]
Training...
Epoch 1/100
/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/callbacks.py:284: RuntimeWarning: Can save best model only with loss available, skipping.
'skipping.' % (self.monitor), RuntimeWarning)
/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/callbacks.py:358: RuntimeWarning: Early stopping requires loss available!
(self.monitor), RuntimeWarning)
Traceback (most recent call last):
File "faces.py", line 127, in
cmd()
File "faces.py", line 65, in train
verbose = True,
File "/mnt/mybk/tests/deconvfaces/faces/train.py", line 182, in train_model
callbacks=callbacks, shuffle=True, verbose=1)
File "/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/engine/training.py", line 1106, in fit
callback_metrics=callback_metrics)
File "/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/engine/training.py", line 844, in _fit_loop
callbacks.on_epoch_end(epoch, epoch_logs)
File "/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/callbacks.py", line 40, in on_epoch_end
callback.on_epoch_end(epoch, logs)
File "/home/kaihuchen01/anaconda2/envs/ph3/lib/python3.5/site-packages/keras/callbacks.py", line 360, in on_epoch_end
if self.monitor_op(current, self.best):
TypeError: unorderable types: NoneType() < float()

Where the content of the directory YALEfaces/yalefaces is as follows (excerpted):

subject01.centerlight subject06.centerlight subject11.centerlight
subject01.glasses subject06.glasses subject11.glasses
subject01.happy subject06.happy subject11.happy
subject01.leftlight subject06.leftlight subject11.leftlight
subject01.noglasses subject06.noglasses subject11.noglasses
subject01.normal subject06.normal subject11.normal
subject01.rightlight subject06.rightlight subject11.rightlight
subject01.sad subject06.sad subject11.sad
(more)

Any advice what I should do in order to rectify this problem?

@somewacko
Copy link
Owner

somewacko commented Oct 24, 2016

Ah, it supports Yale Face Database B (See #3), which is a different data set that was released after the one you're trying to use. It's probably crashing when it's trying to parse the filenames for labels since it doesn't do anything to validate that they're correctly formatted.

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

No branches or pull requests

2 participants