DenseModel
- class lightautoml.ml_algo.torch_based.nn_models.DenseModel(n_in, n_out=1, block_config=[2, 2], drop_rate=0.1, num_init_features=None, compression=0.5, growth_size=256, bn_factor=2, act_fun=torch.nn.ReLU, use_bn=True, **kwargs)[source]
Bases:
ModuleRealisation of ‘dense’ model.
- Parameters:
n_in (
int) – Input dim.n_out (
int) – Output dim.block_config (
List[int]) – List of number of layers within each blockdrop_rate (
Union[float,List[float]]) – Dropout rate for each layer separately or altogether.num_init_features (
Optional[int]) – If not none add fc layer before model with certain dim.compression (
float) – portion of neuron to drop after block.growth_size (
int) – Output dim of every layer.bn_factor (
float) – Dim of intermediate fc is increased times bn_factor in DenseModel layer.act_fun (
Module) – Activation function.use_bn (
bool) – Use BatchNorm.