brainspy.utils.performance.accuracy#

File for training a perceptron after the signal of a Processor class or one of its children.

Functions

evaluate_accuracy(inputs, targets, node)

To evaluate the accuracy of the Perceptron algorithm on the input data ( which is the outut of the DNPU or DNPU architecture ) based on the inputs and target values provided.

get_accuracy(inputs, targets[, configs, node])

To calculate the accuracy of the device on a binary classification task.

get_default_node_configs()

To get a default configuration of the node of a perceptron.

init_results(inputs, targets, configs)

To initialize the results of the accuracy test and the results of the Perceptron algorithm.

plot_perceptron(results[, save_dir, ...])

Plot the results of the perceptron algorithm.

train_perceptron(epochs, dataloader, optimizer)

To train the Perceptron obtain a set of weights w that accurately classifies each instance in our training set.

zscore_norm(inputs[, eps])

To calculate the standard normal distribution from the input data.