def update_firing_dist_and_cat(self):
# Called from update_all_neuron_dists() when LCOMP is updated to seed DIST with best neuron's distance
# Called whenever DIST is read
log.trace("CM1KEmulator.update_firing_dist_and_cat()")
if self.firing_neurons:
self.write_dist_non_ui(self.firing_neurons[-1].dist)
self.write_cat(self.firing_neurons[-1].cat)
if self.firing_neurons[-1].degenerate:
self.write_cat_degenerate(True)
self.firing_neurons.pop()
else:
self.write_dist_non_ui(0xFFFF)
self.write_cat(0xFFFF)
评论列表
文章目录