seq_to_satn#
- seq_to_satn(seq, im=None)[source]#
Converts an image of invasion sequence values to saturation values.
- Parameters:
seq (ndarray) – The image containing invasion sequence values in each voxel. Solid should be indicated as 0’s and uninvaded voxels as -1.
im (ndarray, optional) – A binary image of the porous media, with
True
indicating the void space andFalse
indicating the solid phase. If not given then it is assumed that the solid is identified asseq == 0
.
- Returns:
satn – An ndarray the same size as
seq
but with sequence values replaced by the fraction of void space invaded at or below the sequence number. Solid voxels and uninvaded voxels are represented by 0 and -1, respectively.- Return type:
ndarray
Examples
Click here to view online example.