modified train_cascade.py