Update README.md
This commit is contained in:
1 parent
ee7006a92a
commit
801dc8ec96
1 file changed
+44
-53
@@ -12,43 +12,38 @@ Read [SETUP.md](SETUP.md)
|
|||||||
The directory structure of new project looks like this:
|
The directory structure of new project looks like this:
|
||||||
```
|
```
|
||||||
├── project
|
├── project
|
||||||
│ ├── data <- Data from third party sources
|
│ ├── data <- Data from third party sources
|
||||||
│ │
|
│ │
|
||||||
│ ├── logs <- Logs generated by Weights&Biases and PyTorch Lightning
|
│ ├── data_modules <- Data related modules
|
||||||
|
│ │ ├── datamodules.py <- "LightningDataModule" modules
|
||||||
|
│ │ ├── datasets.py <- "Dataset" modules
|
||||||
|
│ │ └── transforms.py <- Data transformations (data preprocessing)
|
||||||
│ │
|
│ │
|
||||||
│ ├── docs <- Useful pdf files
|
│ ├── logs <- Logs generated by Weights&Biases and PyTorch Lightning
|
||||||
│ │
|
│ │
|
||||||
│ ├── hack_utils <- Any extra scripts not belonging to training pipeline
|
│ ├── utils <- Any extra scripts not belonging to training pipeline
|
||||||
│ │
|
│ │
|
||||||
│ ├── notebooks <- Jupyter notebooks
|
│ ├── notebooks <- Jupyter notebooks
|
||||||
│ │
|
│ │
|
||||||
│ ├── lightning_modules <- PyTorch Lightning related modules
|
│ ├── lightning_modules <- PyTorch Lightning related modules
|
||||||
│ │ ├── data_modules <- Data related modules
|
|
||||||
│ │ │ ├── datamodules.py <- "LightningDataModule" modules
|
|
||||||
│ │ │ ├── datasets.py <- "Dataset" modules
|
|
||||||
│ │ │ └── transforms.py <- Data transformations (data preprocessing)
|
|
||||||
│ │ │
|
|
||||||
│ │ ├── callbacks.py <- Training callbacks
|
│ │ ├── callbacks.py <- Training callbacks
|
||||||
│ │ └── init_utils.py <- Some useful initializers
|
│ │ └── init_utils.py <- Some useful initializers
|
||||||
│ │
|
│ │
|
||||||
│ ├── models
|
│ ├── models
|
||||||
│ │ ├── simple_mnist_classifier <- Example model
|
│ │ ├── simple_mnist_classifier <- Example model
|
||||||
│ │ │ ├── lightning_module.py <- Contains train/val/test step methods
|
│ │ │ ├── lightning_module.py <- Contains train/val/test step methods
|
||||||
│ │ │ ├── models.py <- Neural networks declarations
|
│ │ │ └── models.py <- Models declarations used in lightning_module.py
|
||||||
│ │ │ ├── predict.py <- Predicting from trained model
|
|
||||||
│ │ │ └── __init__.py
|
|
||||||
│ │ │
|
│ │ │
|
||||||
│ │ ├── simple_cifar10_classifier <- Example model
|
│ │ ├── simple_cifar10_classifier <- Example model
|
||||||
│ │ │ ├── lightning_module.py
|
│ │ │ ├── lightning_module.py <- Contains train/val/test step methods
|
||||||
│ │ │ ├── models.py
|
│ │ │ └── models.py <- Models declarations used in lightning_module.py
|
||||||
│ │ │ ├── predict.py
|
|
||||||
│ │ │ └── __init__.py
|
|
||||||
│ │ │
|
│ │ │
|
||||||
│ │ └── ...
|
│ │ └── ...
|
||||||
│ │
|
│ │
|
||||||
│ ├── config.yaml <- Training configuration
|
│ ├── project_config.yaml <- Project configuration
|
||||||
│ ├── execute_sweep.py <- Special file for executing wandb sweeps (hyperparameter search)
|
│ ├── run_configs.yaml <- Different runs configurations
|
||||||
│ └── train.py <- Train model
|
│ ├── execute_sweep.py <- Special file for executing wandb sweeps (hyperparameter search)
|
||||||
|
│ └── train.py <- Train model
|
||||||
│
|
│
|
||||||
├── .gitignore
|
├── .gitignore
|
||||||
├── LICENSE
|
├── LICENSE
|
||||||
@@ -58,39 +53,11 @@ The directory structure of new project looks like this:
|
|||||||
└── requirements.txt
|
└── requirements.txt
|
||||||
```
|
```
|
||||||
|
|
||||||
## Config parameters
|
## Project config parameters
|
||||||
#### [config.yaml](project/config.yaml):
|
#### [project_config.yaml](project/project_config.yaml):
|
||||||
```yaml
|
```yaml
|
||||||
num_of_gpus: -1
|
num_of_gpus: -1
|
||||||
|
|
||||||
model_configs:
|
|
||||||
simple_mnist_classifier_v1:
|
|
||||||
model_folder_name: "simple_mnist_classifier"
|
|
||||||
max_epochs: 3
|
|
||||||
lr: 0.001
|
|
||||||
batch_size: 64
|
|
||||||
weight_decay: 0.000001
|
|
||||||
gradient_clip_val: 0.5
|
|
||||||
accumulate_grad_batches: 1
|
|
||||||
input_size: 784
|
|
||||||
output_size: 10
|
|
||||||
lin1_size: 256
|
|
||||||
lin2_size: 256
|
|
||||||
lin3_size: 128
|
|
||||||
dataset:
|
|
||||||
class_name: "MNISTDataModule"
|
|
||||||
train_transforms: "minst_train_preprocess"
|
|
||||||
test_transforms: "minst_test_preprocess"
|
|
||||||
train_val_split_ratio: 0.8
|
|
||||||
num_workers: 1
|
|
||||||
pin_memory: False
|
|
||||||
|
|
||||||
transfer_learning_cifar10_classifier_v1:
|
|
||||||
...
|
|
||||||
|
|
||||||
transfer_learning_cifar10_classifier_v2:
|
|
||||||
...
|
|
||||||
|
|
||||||
resume_training:
|
resume_training:
|
||||||
lightning_ckpt:
|
lightning_ckpt:
|
||||||
resume_from_ckpt: False
|
resume_from_ckpt: False
|
||||||
@@ -122,9 +89,33 @@ callbacks:
|
|||||||
|
|
||||||
printing:
|
printing:
|
||||||
progress_bar_refresh_rate: 5
|
progress_bar_refresh_rate: 5
|
||||||
weights_summary: "top"
|
weights_summary: "top" # "full"
|
||||||
profiler: False
|
profiler: False
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Run config parameters
|
||||||
|
#### [run_configs.yaml](project/run_configs.yaml):
|
||||||
|
```yaml
|
||||||
|
CIFAR10_CLASSIFIER_V2:
|
||||||
|
trainer:
|
||||||
|
max_epochs: 10
|
||||||
|
gradient_clip_val: 0.5
|
||||||
|
accumulate_grad_batches: 1
|
||||||
|
limit_train_batches: 1.0
|
||||||
|
model:
|
||||||
|
name: "simple_cifar10_classifier"
|
||||||
|
lr: 0.002
|
||||||
|
weight_decay: 0.00001
|
||||||
|
output_size: 10
|
||||||
|
lin1_size: 512
|
||||||
|
lin2_size: 256
|
||||||
|
dataset:
|
||||||
|
name: "CIFAR10DataModule"
|
||||||
|
batch_size: 256
|
||||||
|
train_val_split_ratio: 0.9
|
||||||
|
num_workers: 1
|
||||||
|
pin_memory: False
|
||||||
|
```
|
||||||
|
|
||||||
## Tips
|
## Tips
|
||||||
Read [TIPS.md](TIPS.md)
|
Read [TIPS.md](TIPS.md)
|
||||||
Reference in new issue
Block a user