parent
44f43a5fcc
commit
046f68e844
|
@ -15,7 +15,7 @@ from termcolor import colored
|
|||
|
||||
def read_parquet(file):
|
||||
df = pd.read_parquet(file)
|
||||
return df
|
||||
return df.columns
|
||||
|
||||
|
||||
def main():
|
||||
|
@ -55,15 +55,15 @@ def main():
|
|||
if len(parquet_files) < 3:
|
||||
print("Less than 3 parquet files in the directory")
|
||||
else:
|
||||
dfs = []
|
||||
columns = []
|
||||
for file in parquet_files:
|
||||
df = read_parquet(os.path.join(the_stack_meta_path, file))
|
||||
dfs.append(df)
|
||||
col = read_parquet(os.path.join(the_stack_meta_path, file))
|
||||
columns.append((file, col))
|
||||
|
||||
final_df = pd.concat(dfs)
|
||||
|
||||
print("\n\033[1mFinal DataFrame:\033[0m")
|
||||
print(final_df.info())
|
||||
for file, col in columns:
|
||||
print("\n\033[1m{0}\033[0m:".format(file))
|
||||
for column in col:
|
||||
print(column)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
Loading…
Reference in New Issue