formatting and handling of training indices