rockverse.voxel_image.sphere_pack#

rockverse.voxel_image.sphere_pack(shape, dtype='u1', xlim=(-10, 10), ylim=(-10, 10), zlim=(-10, 10), sphere_radius=1, fill_value=1, **kwargs)[source]#

Create a sphere pack image.

John Finney’s experimental disordered packing of equal, hard spheres, optically imaged in 1970, is hard-coded in RockVerse from the sphere centers available in Digital Rocks Portal. The volumetric image is analytically built in normalized coordinates, with sphere radius equal to 1 and (x, y, z) positions for sphere centers roughly between -20 and 20 in each direction. The image can be built at any needed resolution by a combination of shape and spatial limits.

Note

If you use this data, please remember to cite the data source and the related publications.

Parameters:
  • shape (tuple) – Shape of the image to create.

  • dtype (string or dtype, optional) – NumPy dtype. Default 8-bit unsigned integer.

  • xlim (tuple, optional) – Spatial limits of the sphere pack in the x-direction.

  • ylim (tuple, optional) – Spatial limits of the sphere pack in the y-direction.

  • zlim (tuple, optional) – Spatial limits of the sphere pack in the z-direction.

  • sphere_radius (float, optional) – Radius of the spheres to pack. Default is 1 (original pack, touching, non-overlapping hard spheres). Increase this value to simulate overlapping spheres (cement growth, for example) or decrease to use smaller spheres (like grain dissolution). Sphere centers will not change.

  • fill_value (scalar, optional) – Value to fill the spheres with. Default is 1.

  • **kwargs – Additional keyword arguments to be passed to the underlying creation function.

Returns:

The created VoxelImage object.

Return type:

VoxelImage