Skip to main content
GET
/
sem
/
images
/
{data_id}
/
mask
import requests

response = requests.get(
    "https://api.atomscale.ai/sem/images/d290f1ee-6c54-4b01-90e6-d701748f0851/mask",
    headers={"X-API-KEY": "YOUR_API_KEY"}
)
mask = response.json()
{
  "mask_rle": "0 100 1 50 0 200 ...",
  "mask_height": 1024,
  "mask_width": 1024,
  "color": [0, 0, 255, 0.2]
}
Returns the detected segmentation mask for an SEM image, encoded using run-length encoding (RLE). The mask identifies the features segmented from the image during processing.
data_id
string
required
The data entry UUID for the SEM image

Response

mask_rle
string
Run-length encoded mask data
mask_height
integer
Height of the mask in pixels
mask_width
integer
Width of the mask in pixels
color
array
RGBA color for visualizing the mask
import requests

response = requests.get(
    "https://api.atomscale.ai/sem/images/d290f1ee-6c54-4b01-90e6-d701748f0851/mask",
    headers={"X-API-KEY": "YOUR_API_KEY"}
)
mask = response.json()
{
  "mask_rle": "0 100 1 50 0 200 ...",
  "mask_height": 1024,
  "mask_width": 1024,
  "color": [0, 0, 255, 0.2]
}