Closed RafaelMostert closed 5 years ago
Absolutely! The DataIterator is doing a random shuffle of the images. This is nonsense for the mapping, of course. I will switch the shuffle off for the mapping. Could this be also the reason for #33?
Ok. Good to know.
I don't think that this will also solve #33 . The measure AQE = np.mean(np.min(mapping_data, axis=1))
and the TE measure do not care about ordering. They work as long as the per image mapping is correct.
On a per image basis, the mapping to the SOM works fine. But the ordering returned by the mapping binary seems different from the ordering in the data binary. As if there is some shuffle taking place of the images or the mapping results, at some point in the PINK code.
Here is the test: This time I have a 2x2 (=4 neurons) test SOM. A neuron consisting of only 1s in the top-left, a neuron with only 2s in the top-right, a neuron with only 3s in the bottom-left and a neuron with only 4s in the bottom-right.
The data binary consists of 4 images, all ones, except the first image which contains all 100s. But in the mapping binary it returns as second item in the list..
Here is the code:
Creating this input:
Running Pink:
Loading the mapping:
Result:
While I expect:
I tried mapping different sets of images and it is hard to find a pattern, thus I suspect a random shuffle somewhere... Maybe it is due to the shuffle in
PINK/src/SelfOrganizingMapLib/DataIterator.h
?