def METHOD_NAME(preds, category='ffhq_34'):
    palette = get_palette(category)
    masks = []
    out_imgs = []
    for i, pred in enumerate(preds['pred']):
        pred = np.squeeze(pred)
        masks.append(pred)
        out_img = colorize_mask(pred, palette)
        out_img = Image.fromarray(out_img)
        out_imgs.append(out_img)
    return masks, out_imgs