Giter Club home page Giter Club logo

Comments (3)

AltayAkkus avatar AltayAkkus commented on July 30, 2024

The image seems to be corrupted, try another one.

from rembg.

deiphi avatar deiphi commented on July 30, 2024

It should not be damaged. I used the picture in the example, but it is the same if I change another one.

Traceback (most recent call last):
File "c:\programdata\anaconda3\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\programdata\anaconda3\lib\runpy.py", line 87, in run_code
exec(code, run_globals)
File "C:\ProgramData\Anaconda3\Scripts\rembg.exe_main
.py", line 7, in
File "c:\programdata\anaconda3\lib\site-packages\rembg\cmd\cli.py", line 113, in main
remove(
File "c:\programdata\anaconda3\lib\site-packages\rembg\bg.py", line 83, in remove
model = get_model(model_name)
File "c:\programdata\anaconda3\lib\site-packages\rembg\bg.py", line 72, in get_model
return detect.load_model(model_name="u2net")
File "c:\programdata\anaconda3\lib\site-packages\rembg\u2net\detect.py", line 69, in load_model
net.load_state_dict(torch.load(path))
File "c:\programdata\anaconda3\lib\site-packages\torch\serialization.py", line 595, in load
return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
File "c:\programdata\anaconda3\lib\site-packages\torch\serialization.py", line 781, in _legacy_load
deserialized_objects[key]._set_from_file(f, offset, f_should_read_directly)
RuntimeError: unexpected EOF, expected 383141 more bytes. The file might be corrupted.

from rembg.

Vishvajeet590 avatar Vishvajeet590 commented on July 30, 2024

Hello,

I'm unable to make it work on a Windows.

when i exec cmd: rembg -o animal.png animal-3.jpg

Traceback (most recent call last): File "c:\programdata\anaconda3\lib\runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "c:\programdata\anaconda3\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "C:\ProgramData\Anaconda3\Scripts\rembg.exe\__main__.py", line 7, in <module> File "c:\programdata\anaconda3\lib\site-packages\rembg\cmd\cli.py", line 113, in main remove( File "c:\programdata\anaconda3\lib\site-packages\rembg\bg.py", line 83, in remove model = get_model(model_name) File "c:\programdata\anaconda3\lib\site-packages\rembg\bg.py", line 72, in get_model return detect.load_model(model_name="u2net") File "c:\programdata\anaconda3\lib\site-packages\rembg\u2net\detect.py", line 69, in load_model net.load_state_dict(torch.load(path)) File "c:\programdata\anaconda3\lib\site-packages\torch\serialization.py", line 595, in load return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args) File "c:\programdata\anaconda3\lib\site-packages\torch\serialization.py", line 781, in _legacy_load deserialized_objects[key]._set_from_file(f, offset, f_should_read_directly) RuntimeError: unexpected EOF, expected 383141 more bytes. The file might be corrupted.

Thanks a lot!

How did you installed it. It shows 'rembg' is not recognized as an internal or external command,
operable program or batch file.

from rembg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.