Skip to content

Commit

Permalink
Add index reset to beersheba and esmeralda tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
MiryamMV committed Apr 16, 2020
1 parent bb16d47 commit d7bc106
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion invisible_cities/cities/beersheba_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ def test_create_deconvolution_df(ICDATADIR):
CutType.abs, ecut, 3) for _, t in true_dst.groupby('event')])
true_dst = true_dst.loc[true_dst.E > ecut, :].reset_index(drop=True)

assert_dataframes_close(new_dst, true_dst)
#new_dst .reset_index(drop=True)#
#true_dst.reset_index(drop=True)#
assert_dataframes_close(new_dst .reset_index(drop=True), true_dst.reset_index(drop=True))


@mark.parametrize("cut_type", CutType.__members__)
Expand Down
3 changes: 2 additions & 1 deletion invisible_cities/cities/esmeralda_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ def test_esmeralda_tracks_exact(data_hdst, esmeralda_tracks, correction_map_file
#some events are not in df_tracks_exact
events = df_tracks_exact.event.unique()
df_tracks_cut = df_tracks[df_tracks.event.isin(events)]
assert_dataframes_close (df_tracks_cut[columns2], df_tracks_exact[columns2])

assert_dataframes_close (df_tracks_cut[columns2].reset_index(drop=True), df_tracks_exact[columns2].reset_index(drop=True))
#make sure out_of_map is true for events not in df_tracks_exact
diff_events = list(set(df_tracks.event.unique()).difference(events))
df_summary = dio.load_dst(PATH_OUT, 'Summary', 'Events')
Expand Down

0 comments on commit d7bc106

Please sign in to comment.