Skip to content

Instantly share code, notes, and snippets.

@ashwani-rathee
Created March 25, 2021 18:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ashwani-rathee/6bd782a81bc2398ead2832f0cc59a2dd to your computer and use it in GitHub Desktop.
Save ashwani-rathee/6bd782a81bc2398ead2832f0cc59a2dd to your computer and use it in GitHub Desktop.
Image Morphology Test
import cProfile
from skimage import data
from skimage.util import img_as_ubyte
from skimage import io
from skimage.morphology import disk
from skimage.morphology import erosion
def test():
orig_phantom = img_as_ubyte(data.shepp_logan_phantom())
selem = disk(6)
eroded = erosion(orig_phantom, selem)
print(cProfile.run('test()'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment