code: def prefix_sum_inc(weights):
      """Compute an inclusive prefix sum.
  
      Example:
          >>> prefix_sum_inc([3,4,5])
          [3, 7, 12]
      """
      weights_ = [w for w in weights]
      for x in range(1, len(weights_)):
          weights_[x] += weights_[x - 1]
      return weights_
  
imports: from collections.abc import Iterable
  from deepspeed.moe.utils import is_moe_param
  import os
  import psutil
  import gc
  from math import sqrt
  from math import floor
  from bisect import bisect_left
  import torch
  from torch import inf
  from deepspeed import comm
  from deepspeed.utils import groups, logger
  from deepspeed.runtime.constants import PIPE_REPLICATED
  from numpy import prod
label_desc: Use image node_id 14 for calling a global function with example usage: prefix_sum_inc(weights) and returns: weights_