code: def all_combos(it):
      return list(
          reduce(
              lambda a, b: a + b,
              [list(combinations(it, r)) for r in range(1, len(it))],
              [],
          )
      )
  
file_path: plotly.py/packages/python/plotly/plotly/tests/test_core/test_subplots/test_find_nonempty_subplots.py
imports: import pytest
  import plotly.graph_objects
  from plotly.subplots import make_subplots
  from itertools import combinations, product
  from functools import reduce
label_desc: Use image node_id 1 for calling a global function with example usage: all_combos(it) and returns: list