cdcseacave / openMVS

open Multi-View Stereo reconstruction library
http://cdcseacave.github.io
GNU Affero General Public License v3.0
3.18k stars 891 forks source link

TextureMesh Segmentation Fault #1132

Open yinbc opened 2 months ago

yinbc commented 2 months ago

Issue Description:

I encountered a segmentation fault error while running the TextureMesh module in OpenMVS version 2.3.0. The process terminates unexpectedly after "Segmentation fault (core dumped)". The following is the output from the console.

In addition, ply can be successfully generated without "--export-type obj".

Console Output:

22:49:25 [App     ] Command line: TextureMesh /data/scene_0077_dense.mvs -m /data/scene_0077_dense_mesh.ply -w /data --export-type obj
22:49:25 [App     ] CUDA device 0 initialized: Tesla P40 (compute capability 6.1; memory 22.38GB)
22:49:25 [App     ] Camera model loaded: platform 0; camera  0; f 0.571x0.572; poses 13
22:49:25 [App     ] Scene loaded from interface format (3ms):
        13 images (13 calibrated) with a total of 30.00 MPixels (2.31 MPixels/image)
        1930 points, 0 vertices, 0 faces
22:49:26 [App     ] Mesh loaded: 78623 vertices, 157148 faces (69ms)
Initialized views 13 (100%, 7s98ms)            
22:49:53 [App     ] Assigning the best view to each face completed: 157148 faces (27s422ms)
22:50:35 [App     ] Generating texture atlas and image completed: 679 patches, 8192 image size, 1 textures (41s555ms)
22:50:35 [App     ] Mesh texturing completed: 78623 vertices, 157148 faces (1m8s988ms)
Segmentation fault (core dumped)
yinbc commented 2 months ago

Update, I found that the program crashes when executing "const auto texIdx = faceTexindices[idxFace];" in Mesh::SaveOBJ. After testing, I found that faceTexindices is empty. What is the meaning of faceTexindices?

cdcseacave commented 2 months ago

Are you sure you are using the latest develop branch? Pls send the data and command line to reproduce the crash.

On Wed, Apr 17, 2024 at 15:29 yinbc @.***> wrote:

Update, I found that the program crashes when executing "const auto texIdx = faceTexindices[idxFace];" in Mesh::SaveOBJ. After testing, I found that faceTexindices is empty. What is the meaning of faceTexindices?

— Reply to this email directly, view it on GitHub https://github.com/cdcseacave/openMVS/issues/1132#issuecomment-2061147748, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVMH3QTB54WWWWI2JIKBQ3Y5ZTKHAVCNFSM6AAAAABGJUEA3CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANRRGE2DONZUHA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

yinbc commented 2 months ago

@cdcseacave Thank you for your reply. I am using the latest master branch. I have sent my data and command line to your email.

cdcseacave commented 2 months ago

Latest develop branch

On Wed, Apr 17, 2024 at 18:03 yinbc @.***> wrote:

@cdcseacave https://github.com/cdcseacave Thank you for your reply. I am using the latest master branch. I have sent my data and command line to your email.

— Reply to this email directly, view it on GitHub https://github.com/cdcseacave/openMVS/issues/1132#issuecomment-2061483639, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVMH3VLORDRB7A3HENPCUTY52FNVAVCNFSM6AAAAABGJUEA3CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANRRGQ4DGNRTHE . You are receiving this because you were mentioned.Message ID: @.***>

ansj11 commented 1 week ago

Hi, I want to use this repo to extract texture, but I got failed when building the main branch. will the develop branch solve my problem?

yinbc commented 1 week ago

Hi, I want to use this repo to extract texture, but I got failed when building the main branch. will the develop branch solve my problem?

yes,it worked for me,you can try it

yinbc commented 1 week ago

Latest develop branch On Wed, Apr 17, 2024 at 18:03 yinbc @.> wrote: @cdcseacave https://github.com/cdcseacave Thank you for your reply. I am using the latest master branch. I have sent my data and command line to your email. — Reply to this email directly, view it on GitHub <#1132 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVMH3VLORDRB7A3HENPCUTY52FNVAVCNFSM6AAAAABGJUEA3CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANRRGQ4DGNRTHE . You are receiving this because you were mentioned.Message ID: @.>

thank you!