697 B
697 B
Custom user mask
Jungfraujoch allows to upload custom user mask. This happens in two steps. First create mask in TIFF format:
import numpy as np
import tifffile as tiff
# Create a 2068x2164 numpy array filled with zeros, with 32-bit unsigned integers
array = np.zeros((2068, 2164), dtype=np.uint32)
# Mark the pixel (300, 400) with the value 1
array[300, 400] = 1
# Save the array as a TIFF file
tiff.imwrite('mask.tiff', array)
Pixels with non-zero value in the TIFF file will be marked as belonging to the user mask.
Then upload the mask to Jungfraujoch server:
curl -v http://<jfjoch_broker http address>/config/user_mask.tiff -XPUT --data-binary @mask.tiff