marcellacornia / sam

Predicting Human Eye Fixations via an LSTM-based Saliency Attentive Model. IEEE Transactions on Image Processing (2018)
https://ieeexplore.ieee.org/document/8400593
MIT License
205 stars 76 forks source link

fix_map = scipy.io.loadmat(path)["I"] KeyError: 'I' #15

Closed ghost closed 5 years ago

ghost commented 5 years ago

fix_map = scipy.io.loadmat(path)["I"] KeyError: 'I' please help me,thanks

marcellacornia commented 5 years ago

Hi @chenbolinstudent, thanks for downloading our code.

The data loading functions are compatible with the original release of the SALICON dataset. Which dataset are you using?

ghost commented 5 years ago

I use the SALICON

ghost commented 5 years ago

my configure is cuda9,python2.7,keras=1.1.0,theano=1.0.3,it that any configure require?thanks

ghost commented 5 years ago

I do not know the function of ["I"] in the scipy

marcellacornia commented 5 years ago

The ["I"] is not a function of SciPy. For the original release of the SALICON dataset, authors provided matlab files with the fixation map for each image and the ["I"] is an attribute of those matlab files.

ghost commented 5 years ago

can you give me the source of the original release of the SALICON dataset?thanks

marcellacornia commented 5 years ago

At the end of this page, you can find matlab files and saliency maps of the original release (i.e. the previous one) of the SALICON.

ghost commented 5 years ago

thank you very much

ghost commented 5 years ago

however,when I use the release salicon, i meet the same problem: fix_map = scipy.io.loadmat(path)["I"] KeyError: 'I'

eleboss commented 5 years ago

@chenbolinstudent Hi! There is an old issue talked about this problem: link

Following this modification, you can avoid this problem.

While for me, my loss started from about 180 and suddenly jumped to nan (seems it will never back).

@marcellacornia Could you give us an intro about how to train correctly? Many thanks!

plin24 commented 5 years ago

@eleboss Hi! I'm also experiencing a sudden drop to nan for loss. Did you figure out anything?

eleboss commented 5 years ago

@plin24 Sorry, seems everyone experienced the same issue. I am waiting for the answer from author.

marcellacornia commented 5 years ago

@eleboss @plin24 Hi! Thanks for downloading our code and sorry for the delay.

In our experiments, we did not notice the same behavior during training and it's difficult to understand what caused the problem.

It could be helpful to understand if a specific metric drops to nan. Note that our model is trained by using a combination of three different saliency evaluation metrics (i.e. KL-Divergence, Normalized Scanpath Saliency, and Linear Correlation Coefficient). Could you please try to train the network by using a single metric at a time as loss function?

However, if you are interested, I have released the weights of our model (the ResNet version) also on the new release of the SALICON dataset. You can find them in the Pretrained Models Section of the README.