code: def segment_volumes(neurites, neurite_type=NeuriteType.all):
      '''Volumes of the segments in a collection of neurites'''
      def _func(sec):
          '''list of segment volumes of a section'''
          return [morphmath.segment_volume(seg) for seg in zip(sec.points[:-1], sec.points[1:])]
  
      return map_segments(_func, neurites, neurite_typef segment_volumes(neurites, neurite_type=NeuriteType.all):
      '''Volumes of the segments in a collection of neurites'''
      def _func(sec):
          '''list of segment volumes of a section'''
          return [morphmath.segment_volume(seg) for seg in zip(sec.points[:-1], sec.points[1:])]
  
      return map_segments(_func, neurites, neurite_type)
docs: Volumes of the segments in a collection of neurites