text_plain_output_1.png
import pandas as pd

df1 = pd.read_csv('../input/newspaper-articles-csv-ocr/ocr/df_valid.csv')
df1['imgdir'] = '../input/newspaper-articles/articles/validation'
df2 = pd.read_csv('../input/newspaper-articles-csv-ocr/ocr/df_train1.csv')
df2['imgdir'] = '../input/newspaper-articles/articles/training'
df3 = pd.read_csv('../input/newspaper-articles-csv-ocr/ocr/df_train2.csv')
df3['imgdir'] = '../input/newspaper-articles/articles/training'
df4 = pd.read_csv('../input/newspaper-articles-csv-ocr/ocr/df_train3.csv')
df4['imgdir'] = '../input/newspaper-articles/articles/training'
df = pd.concat([df1, df2, df3, df4])

df = df[df.text.apply(lambda x: len(str(x)) > 1)]
df = df.reset_index(drop=True)
print(df.shape)
df.head()