docs: def get_random_subgraph(graph, number_edges=None, number_seed_edges=None, seed=None, invert_degrees=None):
      """Generate a random subgraph based on weighted random walks from random seed edges.
  
      :type graph: pybel.BELGraph graph
      :param Optional[int] number_edges: Maximum number of edges. Defaults to
       :data:`pybel_tools.constants.SAMPLE_RANDOM_EDGE_COUNT` (250).
      :param Optional[int] number_seed_edges: Number of nodes to start with (which likely results in different components
       in large graphs). Defaults to :data:`SAMPLE_RANDOM_EDGE_SEED_COUNT` (5).
      :param Optional[int] seed: A seed for the random state
      :param Optional[bool] invert_degrees: Should the degrees be inverted? Defaults to true.
      :rtype: pybel.BELGraph
      """
      if number_edges is None:
          number_edges = SAMPLE_RANDOM_EDGE_COUNT
  
      if number_seed_edges is None:
          number_seed_edges = SAMPLE_RANDOM_EDGE_SEED_COUNT
  
      if seed is not None:
          random.seed(seed)
  
      # Check if graph will sample full graph, and just return it if it would
      if graph.number_of_edges() <= number_edges:
          log.info('sampled full graph')
          return graph.copy()
  
      log.debug('getting random sub-graph with %d seed edges, %d final edges, and seed=%s', number_seed_edges,
                number_edges, seed)
  
      # Get initial graph with `number_seed_edges` edges
      result = get_graph_with_random_edges(graph, number_seed_edges)
  
      number_edges_remaining = number_edges - result.number_of_edges()
      _helper(
          result,
          graph,
          number_edges_remaining,
          node_blacklist=set(),  # This is the set of nodes that should no longer be chosen to grow from
          invert_degrees=invert_degrees,
      )
  
      log.debug('removing isolated nodes')
      remove_isolated_nodes(result)
  
      # update metadata
      update_node_helper(graph, result)
      update_metadata(graph, result)
  
      return result