Skip to main content

train

Given a path to an INPUT sequential dataset (.csv, .json, .txt), generates an pre-trained .pt OUTPUT model, trained on that dataset.

Along with all other training parameters, an optional set of data augmentation operations can be provided to be applied in series during training to the input data.

Usage

hxmx train <INPUT> [OUTPUT] [-m <INTEGER>] [-l <INTEGER>] [-hs <INTEGER>] [-c <INTEGER>] [-e <INTEGER>] [-bs <INTEGER>] [--lr <FLOAT>] [-p <INTEGER>] [--dropout <FLOAT>] [--betas <FLOAT RANGE>] [--slope <FLOAT RANGE>] [-n <FLOAT RANGE>] [-s <INTEGER>] [-op <TEXT>] [-d <CHOICE>] [--debug] [--help]

Arguments

NameTypeRequiredDefault
INPUTpath — must exist, file
OUTPUTpath — filemodel.pt

Options

NameTypeDefaultDescription
--mixtures, -minteger10Number of Gaussian mixture components.
--layers, -linteger1Number of recurrent layers.
--hidden-size, -hsinteger120Number of dimensions to use for hidden representation.
--context, -cinteger200Length of sequence segments to use during training.
--epochs, -einteger1000Maximum number of epochs.
--batch-size, -bsinteger32Batch size.
--lrfloat0.0025Learning rate.
--patience, -pinteger15Number of iterations the model is allowed to not improve before stopping training.
--dropoutfloat0.25Dropout rate. During training, randomly zero some of the elements of the input data. Useful to prevent over-fitting.
--betasfloat [0.1, 0.995][0.9, 0.99]Coefficients used for computing running averages of gradient and its square, via Adaptive Moment Estimation (Adam) optimizer.
--slopefloat [0, +∞]1e-05Negative slope for Leaky ReLU activations.
--noise, -nfloat [0, 1][0, 0]Adaptive weight noise parameters, as a pair of standard deviation and decay factor values, respectively. Adds Gaussian noise to the model weights during training, to prevent overfitting.
--seed, -sinteger1Random seed. Use 0 for non-deterministic results.
--operations, -opstring (multiple)[]Data augmentation operation(s) to stochastically apply during training. See operations
--device, -dchoice (auto|cpu| ...)autoComputing device. To list all available devices, run hxmx devices.
--debugbooleanFalseDebug mode. Includes traceback when an error is raised.
-h, --helpbooleanFalseOpen documentation in browser.