File size: 1,055 Bytes
21f4ad5 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# Configuration file for MNIST Classifier Training
# Model Configuration
model:
type: 'cnn' # Options: 'cnn', 'fc'
dropout_rate: 0.3
num_classes: 10
# Training Configuration
training:
epochs: 20
batch_size: 128
initial_lr: 0.001
optimizer: 'adamw' # Options: 'adam', 'adamw', 'sgd'
weight_decay: 0.0001
scheduler: 'onecycle' # Options: 'cosine', 'onecycle', 'step'
warmup_epochs: 2
early_stop_patience: 7
gradient_clip_norm: 1.0
# Data Configuration
data:
data_dir: './data'
val_split: 0.1 # 10% of training data for validation
num_workers: 4
pin_memory: true
# Data Augmentation (for training only)
augmentation:
rotation_degrees: 10
translate: 0.1
scale_range: [0.9, 1.1]
random_erasing_prob: 0.1
# Hardware Configuration
hardware:
use_gpu: true
use_amp: false # Automatic Mixed Precision (set to true for faster training on modern GPUs)
# Logging and Saving
logging:
save_dir: './checkpoints'
log_dir: './runs'
save_freq: 5 # Save checkpoint every N epochs
# Reproducibility
seed: 42 |