web/cutout: add a button to cancel the job

This commit is contained in:
wukko
2025-01-15 23:14:29 +06:00
parent 0e26424355
commit f544768784
2 changed files with 36 additions and 6 deletions

View File

@@ -38,6 +38,9 @@ const removeImageBackground = async (file: File) => {
const model_type = "light";
const model = await AutoModel.from_pretrained(models[model_type].id, {
progress_callback: (progress) => {
console.log(progress);
},
device: "wasm",
dtype: "fp32",
});