added docstrings for the training program