# Generated by pandoc-plot 1.8.0
import matplotlib.pyplot as plt
import numpy as np

np.random.seed(2019)

from skued import diffread
from pathlib import Path

im1 = diffread(Path("images") / "autocenter" / "graphite.tif")
mask1 = diffread(Path("images") / "autocenter" / "graphite_mask.tif").astype(bool)

im2 = diffread(Path("images") / "mnxc" / "Cr_1.tif")
mask2 = np.ones_like(im2, dtype=bool)
mask2[0:1250, 950:1250] = False

fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(6,3))

for ax, im, mask in zip([ax1, ax2], [im1, im2], [mask1, mask2]):

    im[np.logical_not(mask)] = 200
    ax.imshow(im, vmin=0, vmax=200, cmap='inferno')
    ax.axis('off')

plt.tight_layout()
Click here to see how this plot was generated.