cvg / DeepLSD

Implementation of the paper "DeepLSD: Line Segment Detection and Refinement with Deep Image Gradients"
MIT License
486 stars 62 forks source link

ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location) #28

Open 2jjjd opened 1 year ago

2jjjd commented 1 year ago

there is no such a file named 'line_optim' in the file'line_refinement', how to import line_optim from line_refinement in the file deeplsd/models/deeplsd.py?

rpautrat commented 1 year ago

Hi, did you correctly installed deeplsd with the full install, as described in the ReadMe?

ogencoglu commented 1 year ago

Hi-jacking this. Does line refinement mean e.g. double lines will be merged into one with the 'optimize': True config or something else?

rpautrat commented 1 year ago

No, the line refinement is only meant to slightly move a bit the lines to make them perfectly fit the predicted distance and angle fields. So you would keep the same number of lines, including double lines.

houyiliang commented 11 months ago

Hello, it also appears after I complete the configuration according to full install. ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location) how did you solve it? thank you.

rpautrat commented 11 months ago

Hi, can you send here the full output that you get after running the full install command?

reai000 commented 11 months ago

Hi, can you send here the full output that you get after running the full install command?

0

Hi, I also encountered the same problem. Where is the definition of line_optim? Thank you

rpautrat commented 10 months ago

line_optim is defined in the line_refinement folder, with Python bindings. It is installed during the full install described in the Readme.

Note that you only need it to refine lines, but if you just want to use the base version of DeepLSD for inference, you don't need it. The Readme explains how to do this quickstart install.

reai000 commented 10 months ago

I solved it, thank you very much。

whw9483 commented 10 months ago

I solved it, thank you very much。

How was it resolved?