Update README.md
This commit is contained in:
1 parent
9fd884c331
commit
ea7c055044
1 file changed
+16
-8
@@ -101,13 +101,13 @@ You can store many run configurations in this file.<br>
|
|||||||
Example run configuration:
|
Example run configuration:
|
||||||
```yaml
|
```yaml
|
||||||
MNIST_CLASSIFIER_V1:
|
MNIST_CLASSIFIER_V1:
|
||||||
trainer: <- parameters passed to lightning 'Trainer'
|
trainer: <- these parameters will be passed directly to 'Trainer' object
|
||||||
max_epochs: 5
|
max_epochs: 5
|
||||||
gradient_clip_val: 0.5
|
gradient_clip_val: 0.5
|
||||||
accumulate_grad_batches: 1
|
accumulate_grad_batches: 1
|
||||||
limit_train_batches: 1.0
|
limit_train_batches: 1.0
|
||||||
model: <- parameters passed to 'LitModel' in 'hparams' dictionary
|
model: <- these parameters will be passed to 'LightningModule' object in 'hparams' dictionary
|
||||||
model_folder: "simple_mnist_classifier" <- name of folder from which 'lightning_module.py' (with 'LitMdodel' class) will be loaded
|
model_folder: "simple_mnist_classifier"
|
||||||
lr: 0.001
|
lr: 0.001
|
||||||
weight_decay: 0.000001
|
weight_decay: 0.000001
|
||||||
input_size: 784
|
input_size: 784
|
||||||
@@ -115,19 +115,27 @@ MNIST_CLASSIFIER_V1:
|
|||||||
lin1_size: 256
|
lin1_size: 256
|
||||||
lin2_size: 256
|
lin2_size: 256
|
||||||
lin3_size: 128
|
lin3_size: 128
|
||||||
dataset: <- parameters passed to 'DataModule' in 'hparams' dictionary
|
dataset: <- these parameters will be passed to 'LightningDataModule' object in 'hparams' dictionary
|
||||||
datamodule_folder: "mnist_digits_datamodule" <- name of folder from which 'datamodule.py' (with 'DataModule' class) will be loaded
|
datamodule_folder: "mnist_digits_datamodule"
|
||||||
batch_size: 256
|
batch_size: 256
|
||||||
train_val_split_ratio: 0.9
|
train_val_split_ratio: 0.9
|
||||||
num_workers: 1
|
num_workers: 1
|
||||||
pin_memory: False
|
pin_memory: False
|
||||||
wandb: <- this section is optional and can be removed
|
callbacks:
|
||||||
|
ConfusionMatrixLoggerCallback:
|
||||||
|
class_names: ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"]
|
||||||
|
wandb:
|
||||||
group: ""
|
group: ""
|
||||||
tags: ["v1", "uwu"]
|
tags: ["v1", "uwu"]
|
||||||
resume_training: <- this section is optional and can be removed
|
resume_training:
|
||||||
checkpoint_path: "path_to_checkpoint/last.ckpt"
|
checkpoint_path: "path_to_checkpoint/last.ckpt"
|
||||||
wandb_run_id: None <- you can set id of Weights&Biases run that you want to resume but it's optional
|
wandb_run_id: None # optionally set id of Weights&Biases run that you want to resume
|
||||||
```
|
```
|
||||||
|
Each run configuration needs to contain sections `trainer`, `model` and `dataset`. Sections `callbacks`, `wandb` and `resume_training` are optional and can be removed.<br>
|
||||||
|
`model` section always needs to contain `model_folder` parameter (folder from which lightning_module.py will be loaded, which should contain 'LitModel' class).<br>
|
||||||
|
`dataset` section always needs to contain `datamodule_folder` parameter (folder from which datamodule.py will be loaded, which should contain 'DataModule' class).<br>
|
||||||
|
Every parameter in `model` section will be passed to your model class and can be retrieved through 'hparams' dictionary (see example with [simple_mnist_classifier](project/models/simple_mnist_classifier/lightning_module.py)).<br>
|
||||||
|
Every parameter in `dataset` section will be passed to your datamodule class and can be retrieved through 'hparams' dictionary (see example with [mnist_digits_datamodule](project/data_modules/mnist_digits_datamodule/datamodule.py)).
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user