def view_samples(self, show=True):
"""Displays the samples."""
if not self.samples:
return # Nothing to show...
plt.figure("Sample views")
num = len(self.samples)
rows = math.floor(num ** .5)
cols = math.ceil(num / rows)
for idx, img in enumerate(self.samples):
plt.subplot(rows, cols, idx+1)
plt.imshow(img, interpolation='nearest')
if show:
plt.show()
# EXPERIMENT: Try breaking out each output encoder by type instead of
# concatenating them all together. Each type of sensors would then get its own
# HTM. Maybe keep the derivatives with their source?
#
评论列表
文章目录