From 816466293fade4f29df8acccdda08c3d43dfef17 Mon Sep 17 00:00:00 2001 From: Nick Jong Date: Wed, 22 Aug 2018 11:49:45 -0700 Subject: [PATCH] Update activity classifier SFrame iterator test to reflect updated computation of mode (#1025) The golden output before assumed that the mode of [3, 2] is 3. The new algorithm, using a histogram, always returns the first index with maximal count, in this case, 2. --- .../python/turicreate/test/test_sframe_sequence_iterator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/unity/python/turicreate/test/test_sframe_sequence_iterator.py b/src/unity/python/turicreate/test/test_sframe_sequence_iterator.py index 506bec1023..b2b197922c 100644 --- a/src/unity/python/turicreate/test/test_sframe_sequence_iterator.py +++ b/src/unity/python/turicreate/test/test_sframe_sequence_iterator.py @@ -156,7 +156,7 @@ def _prepare_expected_chunked_dataset(self): builder = tc.SFrameBuilder([array.array , int , str , array.array , array.array] , ['features' , 'chunk_len' , 'session_id' , 'target' , 'weights']) builder.append([[0, 0, 1, 10, 2, 20, 3, 30] + [0] * 4 , 4 , 's1' , [1 , 2 , 0] , [1 , 1 , 0] ]) builder.append([[4, 40, 5, 50, 6, 60, 7, 70, 8, 80, 9, 90] , 6 , 's2' , [1 , 1 , 3], [1 , 1 , 1] ]) - builder.append([[10, 100, 11, 110, 12, 120, 13, 130, 14, 140, 15, 150] , 6 , 's3' , [1 ,2, 3], [1 , 1, 1] ]) + builder.append([[10, 100, 11, 110, 12, 120, 13, 130, 14, 140, 15, 150] , 6 , 's3' , [1 ,2, 2], [1 , 1, 1] ]) builder.append([[16, 160, 17, 170] + [0] * 8, 2 , 's3' , [2 ,0 , 0], [1 , 0, 0] ]) self.expected_chunked_2_3 = builder.close()