File tree Expand file tree Collapse file tree
tests/translator/foraging
visual_behavior/translator/foraging Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,6 +27,8 @@ def test_load_time(behavioral_session_output_fixture):
2727def test_load_trials (behavioral_session_output_fixture , trials_df_fixture ):
2828 trials = foraging .load_trials (behavioral_session_output_fixture )
2929
30+ trials_df_fixture ['change_frame' ] += 1
31+
3032 pd .testing .assert_frame_equal (
3133 trials ,
3234 trials_df_fixture ,
Original file line number Diff line number Diff line change @@ -188,6 +188,7 @@ def stringify(x):
188188 trials [col ] = trials [col ].map (stringify )
189189
190190 trials ['change_frame' ] = trials ['change_frame' ].map (lambda x : int (x ) if np .isfinite (x ) else None ) + 1
191+
191192 trials ["change_image_category" ] = trials ["change_image_category" ].apply (lambda x : x if x else '' ) # use empty string instead of NoneType
192193 trials ["change_image_name" ] = trials ["change_image_name" ].apply (lambda x : x if x else '' ) # use empty string instead of NoneType
193194 trials ["initial_image_category" ] = trials ["initial_image_category" ].apply (lambda x : x if x else '' ) # use empty string instead of NoneType
You can’t perform that action at this time.
0 commit comments