Split load_data function