Skip to content

Instantly share code, notes, and snippets.

@aniruddha27
Created June 8, 2020 09:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aniruddha27/29631399502347434669de4d94555179 to your computer and use it in GitHub Desktop.
Save aniruddha27/29631399502347434669de4d94555179 to your computer and use it in GitHub Desktop.
# selecting non-empty outputs
df_show2 = pd.DataFrame(columns=df_rule2_all.columns)
for row in range(len(df_rule2_all)):
if len(df_rule2_all.loc[row,'Output'])!=0:
df_show2 = df_show2.append(df_rule2_all.loc[row,:])
# reset the index
df_show2.reset_index(inplace=True)
df_show2.drop('index',axis=1,inplace=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment