align_image_with_openpnm#

Import packages#

import numpy as np
import porespy as ps
import scipy.ndimage as spim
import matplotlib.pyplot as plt
import skimage
ps.visualization.set_mpl_style()

Create image and variables#

im = ps.generators.blobs([500, 500])
plt.figure(figsize=[7, 7])
plt.axis(False)
plt.imshow(im);
../../../_images/817fb1610caf76de370fc4de0a4eb23358285e745387c019ee18c70257ad2ea7.svg

Apply tool#

im = ps.tools.align_image_with_openpnm(im = im)
plt.figure(figsize=[7, 7])
plt.axis(False)
plt.imshow(im);
../../../_images/4474de0ada4f0a1602c938859142f095e5002fd4e2ebc7be461d5e6abb262d4c.svg