docstr: Splits the folders in 'train_val_path' into the train set and test set,
     and returns the full Train/Validation files.
  
  Args:
  train_val_path (str): Path to the Folder with the Train/Val data
  train_val_ratio (float): Ratio of the Train/Test file ratio
  random_seed (int): Seed for the file shufling
  
  Returns:
  speakers_train (list) : Paths of Speaker Folders for Training Data
  speakers_val (list) : Paths of Speaker Folders for Validation Data
docstr_tok: ["Splits","the","folders","in","'train_val_path","'","into","the","train","set","and","test","set",",","and","returns","the","full","Train\/Validation","files",".","Args",":","train_val_path","(","str",")",":","Path","to","the","Folder","with","the","Train\/Val","data","train_val_ratio","(","float",")",":","Ratio","of","the","Train\/Test","file","ratio","random_seed","(","int",")",":","Seed","for","the","file","shufling","Returns",":","speakers_train","(","list",")",":","Paths","of","Speaker","Folders","for","Training","Data","speakers_val","(","list",")",":","Paths","of","Speaker","Folders","for","Validation","Data"]
code: def train_val_files(
      train_val_path: str,
      train_val_ratio: float = 0.92,
      random_seed: int = 0,
  ) -> Union[List[str], List[str]]:
      """Splits the folders in 'train_val_path' into the train set and test set,
         and returns the full Train/Validation files.
  
      Args:
      train_val_path (str): Path to the Folder with the Train/Val data
      train_val_ratio (float): Ratio of the Train/Test file ratio
      random_seed (int): Seed for the file shufling
  
      Returns:
      speakers_train (list) : Paths of Speaker Folders for Training Data
      speakers_val (list) : Paths of Speaker Folders for Validation Data
      """
      speaker_folders = os.listdir(train_val_path)
  
      np.random.seed(random_seed)
      np.random.shuffle(speaker_folders)
      num_speakers = len(speaker_folders)
  
      num_train = int(train_val_ratio * num_speakers)
      speakers_train = speaker_folders[0:num_train]
      speakers_val = speaker_folders[num_train:]
  
      speakers_train = [
          os.path.join(train_val_path, folder)
          for folder in speakers_train
      ]
      speakers_val = [
          os.path.join(train_val_path, folder)
          for folder in speakers_val
      ]
  
      return speakers_train, speakers_val
  
file_path: espnet/egs2/lrs3/asr1/local/data_prep.py
imports: import argparse
  import logging
  import os
  from pathlib import Path
  from typing import List, Union
  import numpy
label_desc: Use image node_id 1 for calling the DatasetUtils obj's underlying member method code with example usage: obj.train_val_files(train_val_path, train_val_ratio, random_seed) and returns: speakers_train,  speakers_val