input: Write a function to compress a given data sequence by grouping consecutive numbers with the same sign. If the sequence is empty, return an empty list.
  assert compress_sequence([9, -2, 6, 0, -7])==[[9], [-2], [6, 0], [-7]]
  assert compress_sequence([-5, -1, 3, 3, -4])==[[-5, -1], [3, 3], [-4]]
  assert compress_sequence([1, 1, 1, -1, -1])==[[1, 1, 1], [-1, -1]]
  assert compress_sequence([0, 0, 0, 0])==[[0, 0, 0, 0]]
  assert compress_sequence([])==[]
output: def compress_sequence(data):
      if not data:
          return []
      result = []
      current_group = [data[0]]
      for i in range(1, len(data)):
          if (data[i] >= 0 and data[i-1] >= 0) or (data[i] < 0 and data[i-1] < 0):
              current_group.append(data[i])
          else:
              result.append(current_group)
              current_group = [data[i]]
      result.append(current_group)
      return result