English
Languages
English
Bengali
French
Hindi
Italian
Japanese
Korean
Malayalam
Russian
Spanish
Tamil
Turkish
Vietnamese
Shortcuts



DiscriminativeNetwork

class DiscriminativeNetwork[source]

Bases: abc.ABC

Base class for discriminative Quantum or Classical Neural Networks.

This method should initialize the module but raise an exception if a required component of the module is not available.

Methods

get_label(x)

Apply quantum/classical neural network to the given input sample and compute the respective data label

loss(x, y[, weights])

Loss function used for optimization

save_model(snapshot_dir)

Save discriminator model

set_seed(seed)

Set seed.

train(data, weights[, penalty, ...])

Perform one training step w.r.t to the discriminator's parameters