mat_cast & mat_pred tested under new framework