Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
RemoveBG, how to install it?
#5
(04-18-2025, 08:25 PM)" CtrlAltDel Wrote:
(04-18-2025, 12:49 PM)saberwarthog Wrote: For anyone that might be interested by a plugin that is close (but doesn't use Rembg & only works on Linux for now), I found this plugin :
Gimp Background Remover

The installation is quite simple 

Saberwarthog, that is another plugin from the same author I mentioned in my second post.  I'm glad you brought this up and have successfully installed it because I chose not to install it initially and maybe it's not that hard to do if explained.  I'd like to ask you a couple of questions.

First of all, what is an LDF folder?  Do I create that folder and if so, where do I place it and what do I put in it?  Also, what is the deal with the setup.sh file?  Do I run that file, if so from where, or place it somewhere after install or what?  How does that work?

Having a background remover what worked offline would be preferable to one that requires an Internet connection, runs through a website, and is limited to 50 usages a month.


Oh don't worry, the folder in in fact in the Background Remover archive ! (if you clic on the green "<> code" button, there is a "download ZIP" line)
the main folder (that should be renamed "background-remover, from " GIMP-Background-Remover-main") should be organized like this :

background-remover (the folder that has to be put in your "plug-ins" folder of Gimp 3)
|
|- .gitignore
|- background-remover.py (the python script that is the plugin basically)
|- README.md (the readme file explaining the use of the plugin)
|- setup.sh (a file that had to be executed in a terminal, don't worry it's quite easy)
|
|- Ldf (folder, you put the "weights" here after install)
    |
    |- dataset.py
    |- net.py
    |- README.md (another readme)
    |- test.py

Once this folder is put inside the "plug-ins" folder of Gimp 3 & renamed correctly, you have to do 2/3 things first :
  • verify that "background-remover.py" is executable (you should be able to right click on it, and look at its properties, in the "permissions" part, make sure it's allowed to be executed like a program (it should be by default ?))
  • inside the background-remover folder, you should be able to right clic & "open in a terminal" (it depends of your distribution & your desktop tho)
  • in that terminal, you type (or copy / paste) the command under here :

    Code:
    bash ./setup.sh


This command will use the "bash" program to execute the setup.sh inside the folder (this is why there is ./ before setup.sh), and install / compile what is needed to make things work in the plugin (you should see some lines scrolling, python programs being installed, etc...).

After all of this is done, you need the "weights" (basically, the files that had the trainings needed for the background removing to work) to be put in the Ldf folder already installed :
you'll need to download the files pointed by the 2 links : Trained model weights & backbone weights
normally, you will get a "model-40" file (92 Mo) & a "resnet50-19c8e357.pth" file (97,8 Mo), you put both of them inside the Ldf folder.

if everything goes as planned, on the next launch of Gimp you should find the plugin at Filters -> RemoveBackground -> Offline Background Remover
Reply


Messages In This Thread
RemoveBG, how to install it? - by CtrlAltDel - 04-16-2025, 11:39 PM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-17-2025, 01:22 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-18-2025, 08:25 PM
RE: RemoveBG, how to install it? - by saberwarthog - 04-18-2025, 10:50 PM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-19-2025, 02:37 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-19-2025, 11:42 PM
RE: RemoveBG, how to install it? - by rich2005 - 04-20-2025, 08:11 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-20-2025, 09:01 AM
RE: RemoveBG, how to install it? - by rich2005 - 04-20-2025, 09:47 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-20-2025, 10:37 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-20-2025, 11:13 PM
RE: RemoveBG, how to install it? - by rich2005 - 04-21-2025, 09:11 AM
RE: RemoveBG, how to install it? - by CtrlAltDel - 04-22-2025, 10:49 AM

Forum Jump: