spawngen / examples /remove-background.json
LostBeard's picture
SpawnGen Studio f0ac219 (the GitHub Pages AOT build, base href /) (part 2)
f638bf2 verified
Raw History Blame Contribute Delete
1.47 kB
{
"1": {
"class_type": "LoadImage",
"inputs": {
"image": "example.png"
}
},
"2": {
"class_type": "RemoveBackground",
"inputs": {
"bg_removal_model": [
"9",
0
],
"image": [
"1",
0
]
}
},
"3": {
"class_type": "MaskToImage",
"inputs": {
"mask": [
"2",
0
]
}
},
"4": {
"class_type": "EmptyImage",
"inputs": {
"width": 512,
"height": 512,
"batch_size": 1,
"color": 65280
}
},
"5": {
"class_type": "ImageScale",
"inputs": {
"image": [
"1",
0
],
"upscale_method": "bicubic",
"width": 512,
"height": 512,
"crop": "center"
}
},
"6": {
"class_type": "ImageCompositeMasked",
"inputs": {
"destination": [
"4",
0
],
"source": [
"5",
0
],
"x": 0,
"y": 0,
"resize_source": false,
"mask": [
"2",
0
]
}
},
"7": {
"class_type": "SaveImage",
"inputs": {
"images": [
"3",
0
],
"filename_prefix": "mask"
}
},
"8": {
"class_type": "SaveImage",
"inputs": {
"images": [
"6",
0
],
"filename_prefix": "cutout"
}
},
"9": {
"class_type": "LoadBackgroundRemovalModel",
"inputs": {
"bg_removal_name": "RMBG-1.4"
}
}
}