GAN-metrics
GAN-metrics copied to clipboard
Support for real/fake datasets with unequal sizes
In one_nearest_neighbor.NaiveOneNearestNeighborScorer._set_score()
. the lines
length = len(self._argmin)
total = sum(1 for k in range(length) if (k < length / 2) == (self._argmin[k] < length / 2))
self._score = total / length
imply that only works for equally sized real & fake dataset (hence the division by 2).
Consider judging the class label with label_batch
from
image_batch, label_batch = self.session.run(next_batch)
in one_nearest_neighbor.NaiveOneNearestNeighborScorer._set_latent()