{
 "last_node_id": 14,
 "last_link_id": 15,
 "nodes": [
  {
   "id": 1,
   "type": "MarkdownNote",
   "pos": [
    0,
    -394.0
   ],
   "size": [
    640,
    224
   ],
   "flags": {},
   "order": 1,
   "mode": 0,
   "inputs": [],
   "outputs": [],
   "properties": {},
   "widgets_values": [
    "**Needs in ComfyUI's `input` folder:** `example.png`\n\nInpainting with LaMa. Top: the object under a click (Segment, SAM 2.1) is removed; the mask is grown a little so no outline is left. Bottom: a 200 x 200 square near the centre of a 768 px image is filled. To paint your own mask, open the image in the mask editor (right-click > Open in MaskEditor) and connect the MASK output of Load Image to `mask` instead."
   ]
  },
  {
   "id": 2,
   "type": "LoadImage",
   "pos": [
    0.0,
    0.0
   ],
   "size": [
    300,
    340
   ],
   "flags": {},
   "order": 2,
   "mode": 0,
   "inputs": [],
   "outputs": [
    {
     "name": "IMAGE",
     "type": "IMAGE",
     "links": [
      1,
      3,
      8,
      13
     ],
     "slot_index": 0
    },
    {
     "name": "MASK",
     "type": "MASK",
     "links": [],
     "slot_index": 1
    }
   ],
   "properties": {},
   "widgets_values": [
    "example.png",
    "image"
   ]
  },
  {
   "id": 3,
   "type": "FastforksSegment",
   "pos": [
    540.0,
    0.0
   ],
   "size": [
    330,
    230
   ],
   "flags": {},
   "order": 3,
   "mode": 0,
   "inputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "link": 1
    }
   ],
   "outputs": [
    {
     "name": "mask",
     "type": "MASK",
     "links": [
      2
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "title": "object under the click",
   "widgets_values": [
    "sam2.1-hiera-small",
    "auto",
    "auto",
    "384,384",
    "",
    "",
    ""
   ]
  },
  {
   "id": 4,
   "type": "GrowMask",
   "pos": [
    950.0,
    0.0
   ],
   "size": [
    240,
    80
   ],
   "flags": {},
   "order": 4,
   "mode": 0,
   "inputs": [
    {
     "name": "mask",
     "type": "MASK",
     "link": 2
    }
   ],
   "outputs": [
    {
     "name": "MASK",
     "type": "MASK",
     "links": [
      4,
      5
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": [
    12,
    true
   ]
  },
  {
   "id": 5,
   "type": "FastforksInpaint",
   "pos": [
    1270.0,
    0.0
   ],
   "size": [
    330,
    230
   ],
   "flags": {},
   "order": 5,
   "mode": 0,
   "inputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "link": 3
    },
    {
     "name": "mask",
     "type": "MASK",
     "link": 4
    }
   ],
   "outputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "links": [
      7
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "title": "remove the object",
   "widgets_values": [
    "big-lama",
    "auto",
    "auto"
   ]
  },
  {
   "id": 6,
   "type": "MaskToImage",
   "pos": [
    1270.0,
    300.0
   ],
   "size": [
    200,
    30
   ],
   "flags": {},
   "order": 6,
   "mode": 0,
   "inputs": [
    {
     "name": "mask",
     "type": "MASK",
     "link": 5
    }
   ],
   "outputs": [
    {
     "name": "IMAGE",
     "type": "IMAGE",
     "links": [
      6
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": []
  },
  {
   "id": 7,
   "type": "PreviewImage",
   "pos": [
    1680.0,
    340.0
   ],
   "size": [
    300,
    300
   ],
   "flags": {},
   "order": 7,
   "mode": 0,
   "inputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "link": 6
    }
   ],
   "outputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "links": [],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": []
  },
  {
   "id": 8,
   "type": "PreviewImage",
   "pos": [
    1680.0,
    0.0
   ],
   "size": [
    300,
    300
   ],
   "flags": {},
   "order": 8,
   "mode": 0,
   "inputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "link": 7
    }
   ],
   "outputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "links": [],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": []
  },
  {
   "id": 9,
   "type": "ImageToMask",
   "pos": [
    540.0,
    560.0
   ],
   "size": [
    240,
    80
   ],
   "flags": {},
   "order": 9,
   "mode": 0,
   "inputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "link": 8
    }
   ],
   "outputs": [
    {
     "name": "MASK",
     "type": "MASK",
     "links": [
      9,
      10
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": [
    "red"
   ]
  },
  {
   "id": 10,
   "type": "MaskComposite",
   "pos": [
    950.0,
    640.0
   ],
   "size": [
    240,
    130
   ],
   "flags": {},
   "order": 10,
   "mode": 0,
   "inputs": [
    {
     "name": "destination",
     "type": "MASK",
     "link": 9
    },
    {
     "name": "source",
     "type": "MASK",
     "link": 10
    }
   ],
   "outputs": [
    {
     "name": "MASK",
     "type": "MASK",
     "links": [
      11
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": [
    0,
    0,
    "subtract"
   ]
  },
  {
   "id": 11,
   "type": "SolidMask",
   "pos": [
    540.0,
    780.0
   ],
   "size": [
    240,
    100
   ],
   "flags": {},
   "order": 11,
   "mode": 0,
   "inputs": [],
   "outputs": [
    {
     "name": "MASK",
     "type": "MASK",
     "links": [
      12
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": [
    1.0,
    200,
    200
   ]
  },
  {
   "id": 12,
   "type": "MaskComposite",
   "pos": [
    1270.0,
    640.0
   ],
   "size": [
    240,
    130
   ],
   "flags": {},
   "order": 12,
   "mode": 0,
   "inputs": [
    {
     "name": "destination",
     "type": "MASK",
     "link": 11
    },
    {
     "name": "source",
     "type": "MASK",
     "link": 12
    }
   ],
   "outputs": [
    {
     "name": "MASK",
     "type": "MASK",
     "links": [
      14
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": [
    284,
    284,
    "add"
   ]
  },
  {
   "id": 13,
   "type": "FastforksInpaint",
   "pos": [
    1680.0,
    680.0
   ],
   "size": [
    330,
    230
   ],
   "flags": {},
   "order": 13,
   "mode": 0,
   "inputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "link": 13
    },
    {
     "name": "mask",
     "type": "MASK",
     "link": 14
    }
   ],
   "outputs": [
    {
     "name": "image",
     "type": "IMAGE",
     "links": [
      15
     ],
     "slot_index": 0
    }
   ],
   "properties": {},
   "title": "fill a square",
   "widgets_values": [
    "big-lama",
    "auto",
    "auto"
   ]
  },
  {
   "id": 14,
   "type": "PreviewImage",
   "pos": [
    2090.0,
    640.0
   ],
   "size": [
    300,
    300
   ],
   "flags": {},
   "order": 14,
   "mode": 0,
   "inputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "link": 15
    }
   ],
   "outputs": [
    {
     "name": "images",
     "type": "IMAGE",
     "links": [],
     "slot_index": 0
    }
   ],
   "properties": {},
   "widgets_values": []
  }
 ],
 "links": [
  [
   1,
   2,
   0,
   3,
   0,
   "IMAGE"
  ],
  [
   2,
   3,
   0,
   4,
   0,
   "MASK"
  ],
  [
   3,
   2,
   0,
   5,
   0,
   "IMAGE"
  ],
  [
   4,
   4,
   0,
   5,
   1,
   "MASK"
  ],
  [
   5,
   4,
   0,
   6,
   0,
   "MASK"
  ],
  [
   6,
   6,
   0,
   7,
   0,
   "IMAGE"
  ],
  [
   7,
   5,
   0,
   8,
   0,
   "IMAGE"
  ],
  [
   8,
   2,
   0,
   9,
   0,
   "IMAGE"
  ],
  [
   9,
   9,
   0,
   10,
   0,
   "MASK"
  ],
  [
   10,
   9,
   0,
   10,
   1,
   "MASK"
  ],
  [
   11,
   10,
   0,
   12,
   0,
   "MASK"
  ],
  [
   12,
   11,
   0,
   12,
   1,
   "MASK"
  ],
  [
   13,
   2,
   0,
   13,
   0,
   "IMAGE"
  ],
  [
   14,
   12,
   0,
   13,
   1,
   "MASK"
  ],
  [
   15,
   13,
   0,
   14,
   0,
   "IMAGE"
  ]
 ],
 "groups": [
  {
   "id": 1,
   "title": "Inputs",
   "bounding": [
    -30.0,
    -90.0,
    360.0,
    460.0
   ],
   "color": "#88A",
   "font_size": 24,
   "flags": {}
  },
  {
   "id": 2,
   "title": "fastforks",
   "bounding": [
    510.0,
    -90.0,
    1910.0,
    1060.0
   ],
   "color": "#3f789e",
   "font_size": 24,
   "flags": {}
  }
 ],
 "config": {},
 "extra": {},
 "version": 0.4
}