cat_1 = ["A", "B", "C", "D"]
cat_2 = ["C", "A", "E", "A"]
cat_3 = ["NaN","F","NaN","NaN"]
# dictionary of lists
dict = {'image_1': cat_1, 'image_2': cat_2, 'image_3': cat_3}
df = pd.DataFrame(dict)
df
Above I have given the example data, when using "pd.get_dummies(df)" I get the same categorical data's name duplicated with various names. In other words when used pd.get_dummies(df) I get:
As seen value "A" is repeated for image_1 and image_2.
What I am aiming for commonize a single column for every unique value instead of extra columns for the same value

