5 """Loads file and do some fixes to fit it to our standard and make it able to be processed
8 filename (str): s3 full path of filename
9 features (dict): contains delimiter, skip_rows and encoding required for current file
10 session (boto3 obj): AWS client connection
11 rel_col (str): column name used to identify upc/release_id
12 Returns: df (pandas dataframe)
14 delimiter = features[
"delimiter"]
15 skip_rows = features[
"skip_rows"]
16 encoding = features[
"encoding"]
18 df = wr.s3.read_csv(filename, sep=delimiter, skiprows=skip_rows, encoding=encoding, dtype={rel_col:str}, low_memory=
False, boto3_session=session)
21 df = wr.s3.read_csv(filename, sep=delimiter, skiprows=skip_rows, encoding=encoding, low_memory=
False, boto3_session=session)