Updated splitting script