bundle_of_tubes(shape: List[int], spacing: int, distribution=None, smooth=True)[source]#

Create a 3D image of a bundle of tubes, in the form of a rectangular plate with randomly sized holes through it.

  • shape (list) – The size the image, with the 3rd dimension indicating the plate thickness. If the 3rd dimension is not given then a thickness of 1 voxel is assumed.

  • spacing (int) – The center to center distance of the holes. The hole sizes will be distributed between this values down to 3 voxels.

  • distribution (scipy.stats object) – A handle to a scipy stats object with the desired parameters.


image – A boolean array with True values denoting the pore space

Return type:



Click here to view online example.