Open sohailskills opened 9 months ago
same problem. @makidoll
The u2net.onnx model is used to make the image transparent. Since this file is 170MB in size, I guess the developer didn't put it in the repo. There is a code in the code that tries to download this file from a Google Drive link, but I think that code is not working right now.
You can solve the problem this way;
Download the model: https://github.com/danielgatis/rembg/releases/download/v0.0.0/u2net.onnx change: path.resolve("u2net.onnx") in src/index.ts: line 96
/home/Desktop/my_project/back-end/node_modules/rembg-node/dist/gdown.js:5 function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } ^ Error: Failed to download gdrive link at /home/Desktop/my_project/back-end/node_modules/rembg-node/dist/gdown.js:84:23 at Generator.next ()
at fulfilled (/home/Desktop/my_project/back-end/node_modules/rembg-node/dist/gdown.js:5:58)
at processTicksAndRejections (node:internal/process/task_queues:95:5)