""" Configuration for training Mask R-CNN on the Penn-Fudan dataset. """ from configs.base_config import base_config # Create a copy of the base configuration config = base_config.copy() # Update specific values for this experiment config.update( { # Core configuration "config_name": "pennfudan_maskrcnn_v1", "data_root": "data/PennFudanPed", "num_classes": 2, # background + pedestrian # Training parameters - modified for memory constraints "batch_size": 1, # Reduced from 2 to 1 to save memory "num_epochs": 10, # Optimizer settings "lr": 0.002, # Slightly reduced learning rate for smaller batch size "momentum": 0.9, "weight_decay": 0.0005, # Memory optimization settings "pin_memory": False, # Set to False to reduce memory pressure "num_workers": 2, # Reduced from 4 to 2 # Device settings "device": "cuda", } ) # Ensure derived paths or settings are consistent if needed # (Not strictly necessary with this simple structure)