4461f2d4c1f140667b8fe9305efffb4351e54460,snntoolbox/simulation/target_simulators/INI_target_sim.py,SNN,simulate,#SNN#,112
Before Change
output_b_l_t, 2) == 0)] = self._num_timesteps
guesses_b = np.argmin(first_spiketimes_b_l, 1)
else:
guesses_b = np.argmax(np.sum(output_b_l_t, 2), 1)
echo("{:.2%}_".format(np.mean(kwargs[str("truth_b")] ==
guesses_b)))
if self.config.getboolean("conversion", "use_isi_code") and \
all(np.count_nonzero(output_b_l_t, (1, 2)) >= self.top_k):
print("Finished early.")
break
if self.config.getboolean("conversion", "use_isi_code"):
for b in range(self.batch_size):
for l in range(self.num_classes):
spike = 0
for t in range(self._num_timesteps):
if output_b_l_t[b, l, t] != 0:
spike = 1
output_b_l_t[b, l, t] = spike
return np.cumsum(np.asarray(output_b_l_t, bool), 2)
def reset(self, sample_idx):
After Change
else:
spike_sums_b_l = np.sum(output_b_l_t, 2)
undecided_b = np.sum(spike_sums_b_l, 1) == 0
guesses_b = np.argmax(spike_sums_b_l, 1)
none_class_b = -1 * np.ones(self.batch_size)
clean_guesses_b = np.where(undecided_b, none_class_b, guesses_b)
echo("{:.2%}_".format(np.mean(kwargs[str("truth_b")] ==
clean_guesses_b)))
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: NeuromorphicProcessorProject/snn_toolbox
Commit Name: 4461f2d4c1f140667b8fe9305efffb4351e54460
Time: 2017-10-25
Author: bodo.rueckauer@gmail.com
File Name: snntoolbox/simulation/target_simulators/INI_target_sim.py
Class Name: SNN
Method Name: simulate
Project Name: rasbt/mlxtend
Commit Name: aefd8bcf146d6de8f19fc0c3c5873880bc82886f
Time: 2015-02-23
Author: se.raschka@me.com
File Name: mlxtend/sklearn/ensemble.py
Class Name: EnsembleClassifier
Method Name: predict
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: 401ea8b316cb38a57094c695004e4f1714079677
Time: 2020-11-20
Author: beat.buesser@ie.ibm.com
File Name: art/attacks/inference/membership_inference/black_box_rule_based.py
Class Name: MembershipInferenceBlackBoxRuleBased
Method Name: infer